~ubuntu-branches/ubuntu/utopic/coreutils/utopic-proposed

« back to all changes in this revision

Viewing changes to lib/pathmax.h

  • Committer: Package Import Robot
  • Author(s): Colin Watson
  • Date: 2012-11-28 03:03:42 UTC
  • mfrom: (8.3.4 sid)
  • Revision ID: package-import@ubuntu.com-20121128030342-21zanj8354gas5gr
Tags: 8.20-3ubuntu1
* Resynchronise with Debian.  Remaining changes:
  - Make 'uname -i -p' return the real processor/hardware, instead of
    unknown.
  - Build-depend on gettext:any instead of on gettext, so that apt-get can
    properly resolve build-dependencies on the tool when cross-building.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* -*- buffer-read-only: t -*- vi: set ro: */
2
 
/* DO NOT EDIT! GENERATED AUTOMATICALLY! */
3
1
/* Define PATH_MAX somehow.  Requires sys/types.h.
4
 
   Copyright (C) 1992, 1999, 2001, 2003, 2005, 2009-2011 Free Software
 
2
   Copyright (C) 1992, 1999, 2001, 2003, 2005, 2009-2012 Free Software
5
3
   Foundation, Inc.
6
4
 
7
5
   This program is free software; you can redistribute it and/or modify
15
13
   GNU General Public License for more details.
16
14
 
17
15
   You should have received a copy of the GNU General Public License
18
 
   along with this program; if not, write to the Free Software Foundation,
19
 
   Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
 
16
   along with this program; if not, see <http://www.gnu.org/licenses/>.  */
20
17
 
21
18
#ifndef _PATHMAX_H
22
19
# define _PATHMAX_H
68
65
#  define PATH_MAX 1024
69
66
# endif
70
67
 
 
68
# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
 
69
/* The page "Naming Files, Paths, and Namespaces" on msdn.microsoft.com,
 
70
   section "Maximum Path Length Limitation",
 
71
   <http://msdn.microsoft.com/en-us/library/aa365247(v=vs.85).aspx#maxpath>
 
72
   explains that the maximum size of a filename, including the terminating
 
73
   NUL byte, is 260 = 3 + 256 + 1.
 
74
   This is the same value as
 
75
     - FILENAME_MAX in <stdio.h>,
 
76
     - _MAX_PATH in <stdlib.h>,
 
77
     - MAX_PATH in <windef.h>.
 
78
   Undefine the original value, because mingw's <limits.h> gets it wrong.  */
 
79
#  undef PATH_MAX
 
80
#  define PATH_MAX 260
 
81
# endif
 
82
 
71
83
#endif /* _PATHMAX_H */