Namespaces
Variants
Views
Actions

std::gets

From cppreference.com
< cpp‎ | io‎ | c
Revision as of 17:53, 2 November 2012 by P12bot (Talk | contribs)

 
 
 
 
Defined in header <cstdio>
char *gets( char *str );
(deprecated)

Reads stdin into given character string until a newline character is found or end-of-file occurs.

Contents

Parameters

str - character string to be written

Return value

str on success, NULL otherwise

Notes

The bounds checking is not performed, therefore this function is extremely vulnerable to buffer-overflow attacks. Use Template:rlpt instead.

See also

Template:cpp/io/c/dcl list fscanfTemplate:cpp/io/c/dcl list fgetsTemplate:cpp/io/c/dcl list fputs