Unix problem or C problem?

Chris Torek chris at mimsy.UUCP
Wed Jan 18 15:37:19 AEST 1989


In article <245 at ibd.BRL.MIL> heilpern at ibd.BRL.MIL (Mark A. Heilpern) writes:
>	while (fscanf(input,"%d",stars)!=EOF) {
>		fprintf(stderr,"OK to this point.\n");
>		fprintf(output,"%4d |",lines++);
>		stars /= 50;
>		for (count = 0; count <= stars; count++)
>			fprintf(output,"*");
>		fprintf(output,"\n");
>	}

Note especially the first complaint referring to fscanf.

% lint t.c
t.c:
t.c(6): warning: fscanf argument is type (int) rather than pointer (arg 3)
fprintf returns value which is always ignored
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163)
Domain:	chris at mimsy.umd.edu	Path:	uunet!mimsy!chris



More information about the Comp.unix.wizards mailing list