From: Sascha Wildner Date: Thu, 5 Jun 2008 17:53:10 +0000 (+0000) Subject: Include for the definition of NULL. X-Git-Url: https://gitweb.dragonflybsd.org/~lentferj/dragonfly.git/commitdiff_plain/e4dcda4d5339d582978674ce6a4dd36b00ea6f50 Include for the definition of NULL. --- diff --git a/include/dirent.h b/include/dirent.h index 850fd787c4..4d4b6420f1 100644 --- a/include/dirent.h +++ b/include/dirent.h @@ -32,7 +32,7 @@ * * @(#)dirent.h 8.2 (Berkeley) 7/28/94 * $FreeBSD: src/include/dirent.h,v 1.7 1999/12/29 05:01:20 peter Exp $ - * $DragonFly: src/include/dirent.h,v 1.9 2008/05/03 22:07:36 dillon Exp $ + * $DragonFly: src/include/dirent.h,v 1.10 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _DIRENT_H_ @@ -74,9 +74,7 @@ typedef struct _dirdesc { #define __DTF_READALL 0x0008 /* everything has been read */ #define __DTF_SKIPME 0x0010 /* next entry to read not current entry */ -#ifndef NULL -#define NULL 0 -#endif +#include #endif /* _POSIX_SOURCE */ diff --git a/include/locale.h b/include/locale.h index b116a2da44..cfcb6c3941 100644 --- a/include/locale.h +++ b/include/locale.h @@ -1,5 +1,5 @@ /* $NetBSD: src/include/locale.h,v 1.13 2003/08/07 09:44:10 agc Exp $ */ -/* $DragonFly: src/include/locale.h,v 1.4 2007/09/20 07:40:51 hasso Exp $ */ +/* $DragonFly: src/include/locale.h,v 1.5 2008/06/05 17:53:10 swildner Exp $ */ /* * Copyright (c) 1991, 1993 @@ -62,9 +62,7 @@ struct lconv { char int_n_sign_posn; }; -#ifndef NULL -#define NULL 0 -#endif +#include #define LC_ALL 0 #define LC_COLLATE 1 diff --git a/include/stddef.h b/include/stddef.h index cd6f08ed30..0fdbbc22ff 100644 --- a/include/stddef.h +++ b/include/stddef.h @@ -33,7 +33,7 @@ * @(#)stddef.h 8.1 (Berkeley) 6/2/93 * * $FreeBSD: src/include/stddef.h,v 1.2.8.4 2002/08/07 15:49:32 imp Exp $ - * $DragonFly: src/include/stddef.h,v 1.4 2003/11/15 19:28:42 asmodai Exp $ + * $DragonFly: src/include/stddef.h,v 1.5 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _STDDEF_H_ @@ -67,9 +67,7 @@ typedef __wchar_t wchar_t; /* open group */ #endif #endif -#ifndef NULL -#define NULL 0 -#endif +#include #define offsetof(type, member) __offsetof(type, member) diff --git a/include/stdio.h b/include/stdio.h index 4b41fcc2a9..7c7b72f707 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -35,7 +35,7 @@ * * @(#)stdio.h 8.5 (Berkeley) 4/29/95 * $FreeBSD: src/include/stdio.h,v 1.24.2.5 2002/11/09 08:07:20 imp Exp $ - * $DragonFly: src/include/stdio.h,v 1.13 2008/04/15 01:16:12 dillon Exp $ + * $DragonFly: src/include/stdio.h,v 1.14 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _STDIO_H_ @@ -54,9 +54,7 @@ typedef __size_t size_t; #endif -#ifndef NULL -#define NULL 0 -#endif +#include typedef __off_t fpos_t; diff --git a/include/stdlib.h b/include/stdlib.h index 538dafb8b3..12a22fc378 100644 --- a/include/stdlib.h +++ b/include/stdlib.h @@ -32,7 +32,7 @@ * * @(#)stdlib.h 8.5 (Berkeley) 5/19/95 * $FreeBSD: src/include/stdlib.h,v 1.16.2.5 2002/12/13 01:34:00 tjr Exp $ - * $DragonFly: src/include/stdlib.h,v 1.21 2008/01/25 23:32:41 swildner Exp $ + * $DragonFly: src/include/stdlib.h,v 1.22 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _STDLIB_H_ @@ -74,9 +74,7 @@ typedef struct { } lldiv_t; #endif -#ifndef NULL -#define NULL 0 -#endif +#include #define EXIT_FAILURE 1 #define EXIT_SUCCESS 0 diff --git a/include/string.h b/include/string.h index a17917b337..3b716b909f 100644 --- a/include/string.h +++ b/include/string.h @@ -32,7 +32,7 @@ * * @(#)string.h 8.1 (Berkeley) 6/2/93 * $FreeBSD: src/include/string.h,v 1.6.2.3 2001/12/25 00:36:57 ache Exp $ - * $DragonFly: src/include/string.h,v 1.8 2006/12/05 23:14:51 dillon Exp $ + * $DragonFly: src/include/string.h,v 1.9 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _STRING_H_ @@ -51,10 +51,7 @@ typedef __size_t size_t; /* open group */ #endif -#ifndef NULL -#define NULL 0 -#endif - +#include #include __BEGIN_DECLS diff --git a/include/time.h b/include/time.h index b202961e93..e1e8f4f2d9 100644 --- a/include/time.h +++ b/include/time.h @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * @(#)time.h 8.3 (Berkeley) 1/21/94 - * $DragonFly: src/include/time.h,v 1.6 2008/04/09 07:05:54 hasso Exp $ + * $DragonFly: src/include/time.h,v 1.7 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _TIME_H_ @@ -61,9 +61,7 @@ /* Frequency of the clock ticks reported by clock(). */ #define CLOCKS_PER_SEC _BSD_CLOCKS_PER_SEC_ -#ifndef NULL -#define NULL 0 -#endif +#include #ifndef _CLOCK_T_DECLARED #define _CLOCK_T_DECLARED diff --git a/include/unistd.h b/include/unistd.h index 3feb2436a5..c57a1dcf75 100644 --- a/include/unistd.h +++ b/include/unistd.h @@ -32,7 +32,7 @@ * * @(#)unistd.h 8.12 (Berkeley) 4/27/95 * $FreeBSD: src/include/unistd.h,v 1.35.2.10 2002/04/15 12:52:28 nectar Exp $ - * $DragonFly: src/include/unistd.h,v 1.23 2008/05/19 10:21:31 corecode Exp $ + * $DragonFly: src/include/unistd.h,v 1.24 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _UNISTD_H_ @@ -41,15 +41,12 @@ #include #include #include +#include #define STDIN_FILENO 0 /* standard input file descriptor */ #define STDOUT_FILENO 1 /* standard output file descriptor */ #define STDERR_FILENO 2 /* standard error file descriptor */ -#ifndef NULL -#define NULL 0 /* null pointer constant */ -#endif - #ifndef _POSIX_SOURCE #define F_ULOCK 0 /* unlock locked section */ #define F_LOCK 1 /* lock a section for exclusive use */ diff --git a/include/wchar.h b/include/wchar.h index 41286e74c2..7ce01cd267 100644 --- a/include/wchar.h +++ b/include/wchar.h @@ -1,5 +1,5 @@ /* $NetBSD: src/include/wchar.h,v 1.20 2004/05/08 21:57:05 kleink Exp $ */ -/* $DragonFly: src/include/wchar.h,v 1.11 2008/03/10 12:01:50 hasso Exp $ */ +/* $DragonFly: src/include/wchar.h,v 1.12 2008/06/05 17:53:10 swildner Exp $ */ /*- * Copyright (c)1999 Citrus Project, @@ -71,10 +71,7 @@ #include #include /* for FILE* */ - -#ifndef NULL -#define NULL 0 -#endif +#include #ifndef _WCHAR_T_DECLARED #define _WCHAR_T_DECLARED diff --git a/sys/sys/param.h b/sys/sys/param.h index 1e421a072b..b16b705b44 100644 --- a/sys/sys/param.h +++ b/sys/sys/param.h @@ -37,7 +37,7 @@ * * @(#)param.h 8.3 (Berkeley) 4/4/95 * $FreeBSD: src/sys/sys/param.h,v 1.61.2.38 2003/05/22 17:12:01 fjoe Exp $ - * $DragonFly: src/sys/sys/param.h,v 1.48 2008/05/19 10:19:49 corecode Exp $ + * $DragonFly: src/sys/sys/param.h,v 1.49 2008/06/05 17:53:10 swildner Exp $ */ #ifndef _SYS_PARAM_H_ @@ -72,9 +72,7 @@ #define __FreeBSD_version 480101 #endif -#ifndef NULL -#define NULL 0 -#endif +#include #ifndef LOCORE #include