Move stdlib.h to common-defs.h
authorGary Benson <gbenson@redhat.com>
Fri, 25 Jul 2014 16:35:30 +0000 (17:35 +0100)
committerGary Benson <gbenson@redhat.com>
Thu, 7 Aug 2014 08:06:38 +0000 (09:06 +0100)
This commit moves the inclusion of stdlib.h to common-defs.h and
removes all other inclusions.

gdb/
2014-08-07  Gary Benson  <gbenson@redhat.com>

* common/common-defs.h: Include stdlib.h.
* defs.h: Do not include stdlib.h.
* addrmap.c: Likewise.
* bcache.c: Likewise.
* common/buffer.c: Likewise.
* common/common-utils.c: Likewise.
* cp-name-parser.y: Likewise.
* go32-nat.c: Likewise.
* mn10300-linux-tdep.c: Likewise.
* nat/linux-osdata.c: Likewise.
* tui/tui.c: Likewise.
* windows-nat.c: Likewise.

gdb/gdbserver/
2014-08-07  Gary Benson  <gbenson@redhat.com>

* server.h: Do not include stdlib.h.
* inferiors.c: Likewise.
* linux-low.c: Likewise.
* regcache.c: Likewise.
* spu-low.c: Likewise.
* tracepoint.c: Likewise.
* utils.c: Likewise.

21 files changed:
gdb/ChangeLog
gdb/addrmap.c
gdb/bcache.c
gdb/common/buffer.c
gdb/common/common-defs.h
gdb/common/common-utils.c
gdb/cp-name-parser.y
gdb/defs.h
gdb/gdbserver/ChangeLog
gdb/gdbserver/inferiors.c
gdb/gdbserver/linux-low.c
gdb/gdbserver/regcache.c
gdb/gdbserver/server.h
gdb/gdbserver/spu-low.c
gdb/gdbserver/tracepoint.c
gdb/gdbserver/utils.c
gdb/go32-nat.c
gdb/mn10300-linux-tdep.c
gdb/nat/linux-osdata.c
gdb/tui/tui.c
gdb/windows-nat.c

index a6a46d96a47ce0b5c4ff9d1b85a4c706474e35c1..a9bbb7822fdc0ce91397a4a06cb5c147c6dc4dc7 100644 (file)
@@ -1,3 +1,18 @@
+2014-08-07  Gary Benson  <gbenson@redhat.com>
+
+       * common/common-defs.h: Include stdlib.h.
+       * defs.h: Do not include stdlib.h.
+       * addrmap.c: Likewise.
+       * bcache.c: Likewise.
+       * common/buffer.c: Likewise.
+       * common/common-utils.c: Likewise.
+       * cp-name-parser.y: Likewise.
+       * go32-nat.c: Likewise.
+       * mn10300-linux-tdep.c: Likewise.
+       * nat/linux-osdata.c: Likewise.
+       * tui/tui.c: Likewise.
+       * windows-nat.c: Likewise.
+
 2014-08-07  Gary Benson  <gbenson@redhat.com>
 
        * common/common-defs.h: Include stdio.h.
index c8fee389f70e69ff0e6be5ba7630cb0689760fc1..c942c7bd92af3b68b5612102f5f60841ec42d4f8 100644 (file)
@@ -18,9 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-
-#include <stdlib.h>
-
 #include "splay-tree.h"
 #include "gdb_obstack.h"
 #include "addrmap.h"
index 99e9184ef6d0bb156028554cb6ece63f6ac1d121..0c87e2d5e349b3d841f25bc3ef4133a400d4316b 100644 (file)
@@ -26,7 +26,6 @@
 #include "gdb_assert.h"
 
 #include <stddef.h>
-#include <stdlib.h>
 
 /* The type used to hold a single bcache string.  The user data is
    stored in d.data.  Since it can be any type, it needs to have the
index a50c890579587aa7ab5e13a008fcb7f6bd915e4b..c291b3290ceeadd5bd514838a7a1d2b21cae5ff8 100644 (file)
@@ -27,7 +27,6 @@
 #include "buffer.h"
 #include "inttypes.h"
 
-#include <stdlib.h>
 #include <string.h>
 #include <stdint.h>
 
index 0fc7af52965de9a8848c1c71b253847d5a8f10c0..ed95a364821d96de8f5597ac4fbb12340064ef3b 100644 (file)
@@ -28,5 +28,6 @@
 #endif
 
 #include <stdio.h>
+#include <stdlib.h>
 
 #endif /* COMMON_DEFS_H */
index 41ef2895d1f94cdd10d240ce89bc6e0f274ce78d..ab05c9f37794b41d69dce53e35ec29bb0d14257d 100644 (file)
@@ -26,8 +26,6 @@
 #include "gdb_assert.h"
 #include <string.h>
 
-#include <stdlib.h>
-
 /* The xmalloc() (libiberty.h) family of memory management routines.
 
    These are like the ISO-C malloc() family except that they implement
index 6a9d13d448af6f3f8ee0428305131220de4dac54..3199aff6c6dd271d896d7506700725c805c61548 100644 (file)
@@ -31,7 +31,6 @@
 
 #include "defs.h"
 
-#include <stdlib.h>
 #include <unistd.h>
 #include <string.h>
 
index 49e45b80586db2399ff5449af8642a17cf4af441..2e1e06bd6d0cb21a57e7c1485f75db5d4732192f 100644 (file)
@@ -597,9 +597,6 @@ enum gdb_osabi
 
 /* From other system libraries */
 
-#include <stdlib.h>
-
-
 #ifndef atof
 extern double atof (const char *);     /* X3.159-1989  4.10.1.1 */
 #endif
index abdda147274c5788fa49ed7249bbcbba7834bb8b..c5a6455e04c969e1af880b02e454cae7ebe9d126 100644 (file)
@@ -1,3 +1,13 @@
+2014-08-07  Gary Benson  <gbenson@redhat.com>
+
+       * server.h: Do not include stdlib.h.
+       * inferiors.c: Likewise.
+       * linux-low.c: Likewise.
+       * regcache.c: Likewise.
+       * spu-low.c: Likewise.
+       * tracepoint.c: Likewise.
+       * utils.c: Likewise.
+
 2014-08-07  Gary Benson  <gbenson@redhat.com>
 
        * server.h: Do not include stdio.h.
index 48d7700b57f89e5cfc0a8b1a562734ce2929274a..608a99736db3b890f79981753300b5fa39e1f734 100644 (file)
@@ -19,7 +19,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#include <stdlib.h>
 #include "gdbthread.h"
 #include "dll.h"
 
index b3092890afa60fefccdeffaecf09ff6a115e616b..d758330941140cb7163799a5c6dfc3c924d4698b 100644 (file)
@@ -31,7 +31,6 @@
 #include <sys/ioctl.h>
 #include <fcntl.h>
 #include <string.h>
-#include <stdlib.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/syscall.h>
index db99f8c0fa9b85809c63f8a78f4d8b7eef8b7860..86af39cb15ad17bbda2db4750652f59ac8feb283 100644 (file)
@@ -21,8 +21,6 @@
 #include "gdbthread.h"
 #include "tdesc.h"
 #include "rsp-low.h"
-
-#include <stdlib.h>
 #include <string.h>
 
 #ifndef IN_PROCESS_AGENT
index 743a368de21126d61612e59409f4651d3835a9df..a15ba36122b9920365f90a066db51da814b2858d 100644 (file)
@@ -30,7 +30,6 @@
 #include "version.h"
 
 #include <stdarg.h>
-#include <stdlib.h>
 #ifdef HAVE_ERRNO_H
 #include <errno.h>
 #endif
index 67ff1474470934635268cb0374b03ff65793b860..ba2780bc2d493b61042844a3bafae76f0d70e707 100644 (file)
@@ -24,7 +24,6 @@
 #include <sys/ptrace.h>
 #include <fcntl.h>
 #include <string.h>
-#include <stdlib.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/syscall.h>
index 7c4b2911b00ac45db06989f5f3523a1f0a4d06a1..31be953e56be1559d9393c7cfb2790cfe0eb667b 100644 (file)
@@ -7110,7 +7110,6 @@ gdb_ust_init (void)
 #endif /* HAVE_UST */
 
 #include <sys/syscall.h>
-#include <stdlib.h>
 
 static void
 gdb_agent_remove_socket (void)
index b87bcc90bac11fd9c770175b986307bf4d77bbf2..a0febb1ce2d06328f09704098b3dc5ae583070da 100644 (file)
@@ -18,7 +18,6 @@
 
 #include "server.h"
 #include <string.h>
-#include <stdlib.h>
 #if HAVE_ERRNO_H
 #include <errno.h>
 #endif
index 42133d6af469da4dc2854924e8aa9edeea00a853..a8c54fa187032230913d577611c1078137ee7461 100644 (file)
 #include "cli/cli-utils.h"
 #include "inf-child.h"
 
-#include <stdlib.h>
 #include <ctype.h>
 #include <errno.h>
 #include <unistd.h>
index 4377463267cac5e6f8f44802247dbd5f20b8f9d3..1b72efaaf9b4b6cb7ea3fc20be66c17cbc7a57ba 100644 (file)
@@ -33,8 +33,6 @@
 #include "tramp-frame.h"
 #include "linux-tdep.h"
 
-#include <stdlib.h>
-
 /* Transliterated from <asm-mn10300/elf.h>...  */
 #define MN10300_ELF_NGREG 28
 #define MN10300_ELF_NFPREG 32
index dae637bd930887d850ed46fa9ac7062743a060ca..d9d1325ae1ddd0ebf675b1a33934ff05937f1a99 100644 (file)
@@ -28,7 +28,6 @@
 #include <sys/types.h>
 #include <sys/sysinfo.h>
 #include <ctype.h>
-#include <stdlib.h>
 #include <string.h>
 #include <utmp.h>
 #include <time.h>
index 413ec204fa708ef6e832e740c5116b86836412e6..7add8ba65b3e03b55c18e45bbe44ca4c04bc9aeb 100644 (file)
@@ -38,7 +38,6 @@
 #include "symtab.h"
 #include "source.h"
 
-#include <stdlib.h>
 #include <ctype.h>
 #include <signal.h>
 #include <fcntl.h>
index 3d101a1b9afbe1e50a75a95a5b26eed6909f1589..5dcd520fbabe62a0ba39531aa82bd3fe9aea0691 100644 (file)
@@ -35,7 +35,6 @@
 #include <signal.h>
 #include <sys/types.h>
 #include <fcntl.h>
-#include <stdlib.h>
 #include <windows.h>
 #include <imagehlp.h>
 #include <psapi.h>