Date: Sat, 4 Jun 2005 20:17:30 +0200 From: Victor Balada Diaz <victor@bsdes.net> To: freebsd-hackers@freebsd.org Subject: Re: help me with C languaje please, re: files. Message-ID: <20050604181730.GB49520@pato.euesrg02.net> In-Reply-To: <a9e342b505060411114e0fe3fd@mail.gmail.com> References: <a9e342b505060411114e0fe3fd@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Jun 04, 2005 at 02:11:01PM -0400, Pablo Mora wrote: > Hi all, > > I am programming in C and I need to read a quantity of lines of a > file. How can I know when a line arrives at his end? exists some > special character? exists some file in C in the kernel of FreeBSD > (4.11) where I can find somewhat similar? > > example: how read four lines of a file. Take a look at fgets(3). The end of line character (in FreeBSD) is '\n'. -- La prueba mas fehaciente de que existe vida inteligente en otros planetas, es que no han intentado contactar con nosotros.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050604181730.GB49520>