Path: utzoo!attcan!uunet!husc6!bloom-beacon!apple!amdahl!pacbell!pbhyf!rob From: rob@pbhyf.PacBell.COM (Rob Bernardo) Newsgroups: comp.lang.c Subject: Re: retiring gets(3) Message-ID: <4294@pbhyf.PacBell.COM> Date: 24 Nov 88 20:39:48 GMT References: <5450@saturn.ucsc.edu> <225800095@uxe.cso.uiuc.edu> Reply-To: rob@pbhyf.PacBell.COM (Rob Bernardo) Organization: Pacific * Bell, San Ramon, CA Lines: 23 In article <225800095@uxe.cso.uiuc.edu> mcdonald@uxe.cso.uiuc.edu writes: +>I suspect that I am far from the only one who would be most +>interested in learning to use gets(3) safely. +I don't understand how you can get something like + gets(3); +past a compiler. Isn't 'gets' supposed to take a char * argument, +not an int literal? You win the Gracie Allen Award of C! Reminds me of something that happened in code walkthrough. One of the reviewers noticed that all the exit statements were: exit(2); and asked the programmer why an exit value of two was used regardless of the exit conditions. The programmer replied, "That's what it says on the top of the man page." -- Rob Bernardo, Pacific Bell UNIX/C Reusable Code Library Email: ...![backbone]!pacbell!pbhyf!rob OR rob@pbhyf.PacBell.COM Office: (415) 823-2417 Room 4E750A, San Ramon Valley Administrative Center Residence: (415) 827-4301 R Bar JB, Concord, California