1
0
mirror of git://git.sv.gnu.org/coreutils.git synced 2026-04-19 10:15:48 +02:00
Files
coreutils/lib/getline.c

33 lines
1.0 KiB
C
Raw Normal View History

2005-09-22 06:44:26 +00:00
/* getline.c --- Implementation of replacement getline function.
Copyright (C) 2005 Free Software Foundation, Inc.
1995-09-19 14:30:59 +00:00
2005-09-22 06:44:26 +00:00
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; either version 2, or (at
your option) any later version.
1995-09-19 14:30:59 +00:00
2005-09-22 06:44:26 +00:00
This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
1995-09-19 14:30:59 +00:00
2003-06-17 19:57:27 +00:00
You should have received a copy of the GNU General Public License
2005-09-22 06:44:26 +00:00
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA. */
1995-09-19 14:30:59 +00:00
2005-09-22 06:44:26 +00:00
/* Written by Simon Josefsson. */
1995-09-19 14:30:59 +00:00
2005-09-22 06:44:26 +00:00
#ifdef HAVE_CONFIG_H
1996-04-22 03:02:55 +00:00
# include <config.h>
1995-09-19 14:30:59 +00:00
#endif
2005-09-22 06:44:26 +00:00
#include "getdelim.h"
2003-06-17 19:57:27 +00:00
#include "getline.h"
2003-08-07 09:26:06 +00:00
ssize_t
2005-09-22 06:44:26 +00:00
getline (char **lineptr, size_t *n, FILE *stream)
1996-04-22 03:02:55 +00:00
{
2005-09-22 06:44:26 +00:00
return getdelim (lineptr, n, '\n', stream);
1996-04-22 03:02:55 +00:00
}