[comp.os.vms] VAX C on VMS 4.6

LEICHTER@VENUS.YCC.YALE.EDU ("Jerry Leichter ", LEICHTER-JERRY@CS.YALE.EDU) (11/19/87)

	VAX C on VMS 4.6 does not seem to pick up the first character
	(reading in from a file).  Anyway to work around/fix this?

This is probably the perfect example of how NOT to ask for information.  The
following is a correct, if completely useless, answer:

	"It works just fine for me.  You are doing something wrong."

Now, perhaps you can describe what you are doing, and what you SEE going
wrong, rather than making incorrect surmises about the problem?

Independent of all that, a clue:  There is a bug in the VAX C library for
VMS V4.6 which breaks the connection between unget() and scanf() (and perhaps
other input routines, I'm not sure).  If you unget() a character, getchar()
will see it, but scanf() will ignore it.
							-- Jerry

PS:  In case you are wondering what kind of code change could produce this
strange effect, I did, too.  It seems that the Draft ANSI C standard added a
new function to fflush():  Flushing an input file discards any ungotten
character.  A side-effect of making this work caused the bug described.