FGETLINE(3)

πŸ“¦
version 2022.10.16 Β· 2 versions
, in opensuse-leap 16.0

okay bestie, welcome to FGETLINE(3) from SchilyΒ΄s LIBRARY FUNCTIONS πŸ’– this one is lowkey iconic and does exactly what it says on the tin.

🌸 NAME 🌸

fgetline() β€” gets a line from a file, periodt ✨

πŸŽ€ SYNOPSIS πŸŽ€

int fgetline(f,buf,length)
FILE *f;
char *buf;
int length;

πŸ¦‹ DESCRIPTION πŸ¦‹

So fgetline() reads up to length characters from the input file using getc() (q.v.). The transfer is also terminated by a newline, end of file, or read error. The newline character is stripped and the string is NULL ('\0') terminated. That's the whole vibe. πŸ’…

πŸ‘‘ RETURNS πŸ‘‘

  • >=0 β€” the number of bytes read.
  • < 0 β€” if an error occurred.

mwah πŸ’‹ huge shoutout to Joerg Schilling, dated 2022/09/09, and this absolute queen of a page is FGETLINE(3) β€” from SchilyΒ΄s LIBRARY FUNCTIONS. bye bestie, go read some lines 🫢🌈

πŸ“¦ where this page comes from