headers: Drop nonstandard null.h and size_t.h.
They're holdovers from R5. <stddef.h> should just be included instead, and ssize_t declared directly in sys/types.h.
This commit is contained in:
@@ -7,7 +7,8 @@
|
||||
|
||||
|
||||
#include <locale_t.h>
|
||||
#include <null.h>
|
||||
#include <stddef.h>
|
||||
|
||||
|
||||
struct lconv {
|
||||
char *decimal_point;
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
/*
|
||||
* Copyright 2008-2012 Haiku, Inc. All Rights Reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
#ifndef _NULL_H
|
||||
#define _NULL_H
|
||||
|
||||
#ifndef NULL
|
||||
#define NULL 0
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -1,19 +0,0 @@
|
||||
/*
|
||||
* Copyright 2008-2012 Haiku, Inc. All Rights Reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
#ifndef _SIZE_T_H_
|
||||
#define _SIZE_T_H_
|
||||
|
||||
|
||||
#include <stddef.h>
|
||||
|
||||
|
||||
/* ATM we don't define ssize_t for GCC2 */
|
||||
#if __GNUC__ > 2 && !defined(__ssize_t__)
|
||||
# define __ssize_t__
|
||||
typedef long signed int ssize_t;
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* _SIZE_T_H_ */
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <null.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
|
||||
|
||||
@@ -9,11 +9,11 @@
|
||||
#include <alloca.h>
|
||||
#include <div_t.h>
|
||||
#include <limits.h>
|
||||
#include <stddef.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/wait.h>
|
||||
#include <wchar_t.h>
|
||||
|
||||
|
||||
#define RAND_MAX 0x7fffffff
|
||||
#define MB_CUR_MAX (__ctype_get_mb_cur_max())
|
||||
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
/*
|
||||
* Copyright 2002-2012 Haiku, Inc. All Rights Reserved.
|
||||
* Copyright 2002-2026, Haiku, Inc. All rights reserved.
|
||||
* Distributed under the terms of the MIT License.
|
||||
*/
|
||||
#ifndef _SYS_TYPES_H
|
||||
#define _SYS_TYPES_H
|
||||
|
||||
|
||||
#include <config/types.h>
|
||||
|
||||
#include <BeBuild.h>
|
||||
#include <config/types.h>
|
||||
#include <stddef.h>
|
||||
|
||||
|
||||
/* BSD compatibility */
|
||||
@@ -18,13 +18,18 @@ typedef unsigned short u_short;
|
||||
typedef unsigned char u_char;
|
||||
|
||||
|
||||
/* sysV compatibility */
|
||||
/* SysV compatibility */
|
||||
typedef unsigned long ulong;
|
||||
typedef unsigned short ushort;
|
||||
typedef unsigned int uint;
|
||||
typedef unsigned char unchar;
|
||||
|
||||
|
||||
#if __GNUC__ > 2 && !defined(__ssize_t__)
|
||||
#define __ssize_t__
|
||||
typedef long signed int ssize_t;
|
||||
#endif
|
||||
|
||||
typedef __haiku_int64 blkcnt_t;
|
||||
typedef __haiku_std_int32 blksize_t;
|
||||
typedef __haiku_int64 fsblkcnt_t;
|
||||
@@ -43,9 +48,9 @@ typedef __haiku_std_uint32 umode_t;
|
||||
typedef __haiku_std_int32 nlink_t;
|
||||
|
||||
#ifdef __HAIKU_BEOS_COMPATIBLE_TYPES
|
||||
typedef int daddr_t; /* disk address */
|
||||
typedef int daddr_t; /* disk address */
|
||||
#else
|
||||
typedef off_t daddr_t; /* disk address */
|
||||
typedef off_t daddr_t; /* disk address */
|
||||
#endif
|
||||
typedef char* caddr_t;
|
||||
|
||||
@@ -122,8 +127,6 @@ struct _pthread_spinlock {
|
||||
};
|
||||
|
||||
|
||||
#include <null.h>
|
||||
#include <size_t.h>
|
||||
#include <time.h>
|
||||
|
||||
#endif
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
#define _UNISTD_H_
|
||||
|
||||
|
||||
#include <null.h>
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
|
||||
@@ -51,7 +51,6 @@
|
||||
# endif
|
||||
#else
|
||||
# include <KernelExport.h>
|
||||
# include <null.h>
|
||||
# if DEBUG_PRINT
|
||||
# define __out dbg_printf
|
||||
# define __outv dbg_vprintf
|
||||
|
||||
@@ -44,7 +44,6 @@
|
||||
# endif
|
||||
#else
|
||||
# include <KernelExport.h>
|
||||
# include <null.h>
|
||||
# if DEBUG_PRINT
|
||||
# define __out dbg_printf
|
||||
# else
|
||||
|
||||
Reference in New Issue
Block a user