Get rid of malloc.h.
This is a non-POSIX/ISO-C header. It is ok to include this on Linux, but it is obsolete on BSD; FreeBSD even throws an error if you include it with __STDC__ defined. Every system should nowadays have malloc() defined in stdlib.h. Diff is largely mechanical, replacing malloc.h with stdlib.h where it is not yet included anyway.
This commit is contained in:
committed by
Jon Trulson
parent
18a5139d7a
commit
0bbd4ff9aa
@@ -37,7 +37,6 @@
|
||||
#define _API_STORAGE_H
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <malloc.h>
|
||||
#include "util/tt_object.h"
|
||||
#include "util/tt_list.h"
|
||||
|
||||
|
||||
@@ -35,13 +35,10 @@
|
||||
*/
|
||||
|
||||
#include "tt_options.h"
|
||||
#if defined(OPT_BUG_SUNOS_4) && defined(__GNUG__)
|
||||
# include <stdlib.h>
|
||||
#endif
|
||||
#include <stdlib.h>
|
||||
#include <rpc/rpc.h>
|
||||
#include "api/c/api_xdr.h"
|
||||
#include <mp/mp_xdr_functions.h>
|
||||
#include <malloc.h>
|
||||
|
||||
bool_t
|
||||
_tt_xdr_cstring_list(XDR *xdrs, char ***ar)
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
*/
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include "api/c/tt_c.h"
|
||||
#include "ttdnd.h"
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ extern "C" { extern int ioctl (int, int, ...) ; };
|
||||
#include "mp/mp_desktop.h"
|
||||
#include "mp/mp_mp.h"
|
||||
#include <unistd.h>
|
||||
#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include "util/tt_gettext.h"
|
||||
|
||||
static int parse_Xdisplay_string(_Tt_string display,
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
#include "api/c/api_error.h"
|
||||
#include <errno.h>
|
||||
#include <sys/resource.h>
|
||||
#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include "tt_options.h"
|
||||
|
||||
#if defined(_AIX)
|
||||
|
||||
@@ -101,7 +101,7 @@ typedef union
|
||||
# define _TT_TRACE_LINETERM 280
|
||||
# define _TT_TRACE_PARSE_EOF 281
|
||||
|
||||
#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include <memory.h>
|
||||
#include <values.h>
|
||||
|
||||
|
||||
@@ -37,7 +37,6 @@
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <malloc.h>
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#include "util/tt_new.h"
|
||||
|
||||
Reference in New Issue
Block a user