Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 20 Feb 2001 09:55:12 +0400
From:      "Arthur Boynagryan" <>
To:        <>
Subject:   Alternative to gets() function?
Message-ID:  <000001c09b01$b1865fa0$4a07a8c0@user0000011909>

Next in thread | Raw E-Mail | Index | Archive | Help
Hi all!

I've been reading man page for gets() and fgets() and noticed 
the following:

"Since it is usually impossible to ensure that the next input 
line is less than some arbitrary length, and because overflowing
the input buffer is almost invariably a security violation, 
programs should NEVER use gets()."

What can you recommend instead of gets()? Does this also 
apply to fgets()? I'm mostly interested in fgets().



To Unsubscribe: send mail to
with "unsubscribe freebsd-questions" in the body of the message

Want to link to this message? Use this URL: <$b1865fa0$4a07a8c0>