File tree Expand file tree Collapse file tree 1 file changed +18
-15
lines changed Expand file tree Collapse file tree 1 file changed +18
-15
lines changed Original file line number Diff line number Diff line change 59
59
60
60
#include <sys/types.h>
61
61
62
-
63
- # undef __P
62
+ #undef __P
64
63
#if defined(__STDC__ )
65
- # define __P (x ) x
66
64
# include <stdarg.h>
67
65
# if !defined(__P )
68
66
# define __P (x ) x
69
67
# endif
70
68
#else
71
- # undef __P
72
69
# define __P (x ) ()
73
- # define const
70
+ # if !defined(const )
71
+ # define const
72
+ # endif
74
73
# include <varargs.h>
75
74
#endif
76
75
#ifndef _BSD_VA_LIST_
77
76
#define _BSD_VA_LIST_ va_list
78
77
#endif
79
78
79
+ #ifdef __STDC__
80
+ # include <limits.h>
81
+ #else
82
+ # ifndef LONG_MAX
83
+ # ifdef HAVE_LIMITS_H
84
+ # include <limits.h>
85
+ # else
86
+ /* assuming 32bit(2's compliment) long */
87
+ # define LONG_MAX 2147483647
88
+ # endif
89
+ # endif
90
+ #endif
91
+
80
92
#if defined(__hpux ) && !defined(__GNUC__ )
81
93
#define const
82
94
#endif
@@ -359,22 +371,13 @@ static BSD__sfvwrite(fp, uio)
359
371
#define u_short unsigned short
360
372
#define u_int unsigned int
361
373
362
- #if !defined(__CYGWIN32__ ) && ( defined(__hpux ) && !defined(__GNUC__ ) )
374
+ #if !defined(__CYGWIN32__ ) && defined(__hpux ) && !defined(__GNUC__ )
363
375
#include <stdlib.h>
364
376
#endif
365
377
#if defined(__hpux ) && !defined(__GNUC__ )
366
378
#include <string.h>
367
379
#endif
368
380
369
- #if defined(__STDC__ )
370
- # include <stdarg.h>
371
- #else
372
- # include <varargs.h>
373
- # undef __P
374
- # define __P (x ) ()
375
- #endif
376
-
377
-
378
381
/*
379
382
* Flush out all the vectors defined by the given uio,
380
383
* then reset it so that it can be reused.
You can’t perform that action at this time.
0 commit comments