In all conscience, while ( (c = getc()) != EOF ) ought to work. If somebody is to be blamed, it is surely not the people who wrote the code, but the people who made a C implementation that broke it. -------