How do I make sure that sys.stdout (or sys.stdin) is in "binary" mode? This seems to work, is it the "right" way of doing it? sys.stdout = os.fdopen(sys.stdout.fileno(),'wb') -- Grant Edwards grante Yow! -- I can do at ANYTHING... I can visi.com even... SHOPLIFT!!