Output stream wasnt getting set