stdin is the file stream
Showing posts with label fgets. Show all posts
Showing posts with label fgets. Show all posts
Saturday, May 25, 2013
Friday, May 24, 2013
gets & fgets
gets is a not a safe method to get data as it allows unbounded String size - leading to buffer overflows.
Should use fgets as a buffer size must be provided as an argument.
Should use fgets as a buffer size must be provided as an argument.
Friday, April 5, 2013
fgets
Reads characters from stream and stores them as a C string into str until (num-1) characters have been read or either a newline or the end-of-file is reached, whichever happens first.
http://www.cplusplus.com/reference/cstdio/fgets/
http://www.cplusplus.com/reference/cstdio/fgets/
Subscribe to:
Posts (Atom)