/[bison]/bison/lib/strnlen.c
ViewVC logotype

Diff of /bison/lib/strnlen.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by eggert, Fri Oct 26 07:26:00 2001 UTC revision 1.3 by eggert, Mon Aug 12 14:11:02 2002 UTC
# Line 1  Line 1 
1  /* Find the length of STRING, but scan at most MAXLEN characters.  /* Find the length of STRING, but scan at most MAXLEN characters.
2     Copyright (C) 1996, 1997, 1998, 2000, 2001 Free Software Foundation, Inc.     Copyright (C) 1996, 1997, 1998, 2000-2002 Free Software Foundation, Inc.
3     This file is part of the GNU C Library.     This file is part of the GNU C Library.
4    
5     The GNU C Library is free software; you can redistribute it and/or     This program is free software; you can redistribute it and/or modify
6     modify it under the terms of the GNU Library General Public License as     it under the terms of the GNU General Public License as published by
7     published by the Free Software Foundation; either version 2 of the     the Free Software Foundation; either version 2, or (at your option)
8     License, or (at your option) any later version.     any later version.
9    
10     The GNU C Library is distributed in the hope that it will be useful,     This program is distributed in the hope that it will be useful,
11     but WITHOUT ANY WARRANTY; without even the implied warranty of     but WITHOUT ANY WARRANTY; without even the implied warranty of
12     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13     Library General Public License for more details.     GNU General Public License for more details.
14    
15     You should have received a copy of the GNU Library General Public     You should have received a copy of the GNU General Public License
16     License along with the GNU C Library; see the file COPYING.LIB.  If not,     along with this program; if not, write to the Free Software Foundation,
17     write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,     Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
    Boston, MA 02111-1307, USA.  */  
18    
19  #if HAVE_CONFIG_H  #if HAVE_CONFIG_H
20  # include <config.h>  # include <config.h>
# Line 25  Line 24 
24  # if !STDC_HEADERS && HAVE_MEMORY_H  # if !STDC_HEADERS && HAVE_MEMORY_H
25  #  include <memory.h>  #  include <memory.h>
26  # endif  # endif
27    /* Temporarily redefine strnlen so that an inconsistent prototype
28       (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't cause trouble.  */
29    # define strnlen system_strnlen
30  # include <string.h>  # include <string.h>
31    # undef strnlen
32  #else  #else
33  # include <strings.h>  # include <strings.h>
34  #endif  #endif

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26