From 733677e2c21b1ea3789c5296c84c1730d9ce498d Mon Sep 17 00:00:00 2001 From: "kay.sievers@vrfy.org" Date: Sat, 5 Mar 2005 07:16:21 +0100 Subject: [PATCH] [PATCH] klibc_fixups: remove unneeded stuff --- Makefile | 1 - klibc_fixups/malloc.h | 9 --------- klibc_fixups/mntent.h | 39 --------------------------------------- libsysfs/dlist.c | 1 + libsysfs/dlist.h | 5 +++-- libsysfs/sysfs.h | 1 - 6 files changed, 4 insertions(+), 52 deletions(-) delete mode 100644 klibc_fixups/malloc.h delete mode 100644 klibc_fixups/mntent.h diff --git a/Makefile b/Makefile index 99a76187..7c159b3d 100644 --- a/Makefile +++ b/Makefile @@ -202,7 +202,6 @@ ifeq ($(strip $(USE_KLIBC)),true) HEADERS += \ klibc_fixups/klibc_fixups.h \ - klibc_fixups/mntent.h \ klibc_fixups/pwd.h KLIBC_FIXUP_OBJS = \ diff --git a/klibc_fixups/malloc.h b/klibc_fixups/malloc.h deleted file mode 100644 index 439608e3..00000000 --- a/klibc_fixups/malloc.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifdef __KLIBC__ - -#ifndef _MALLOC_H -#define _MALLOC_H - -#include - -#endif /* _MALLOC_H */ -#endif /* __KLIBC__ */ diff --git a/klibc_fixups/mntent.h b/klibc_fixups/mntent.h deleted file mode 100644 index ea79a2dd..00000000 --- a/klibc_fixups/mntent.h +++ /dev/null @@ -1,39 +0,0 @@ -#ifdef __KLIBC__ - -#ifndef _MNTENT_H -#define _MNTENT_H - -#include - -struct mntent -{ - char *mnt_fsname; - char *mnt_dir; - char *mnt_type; - char *mnt_opts; - int mnt_freq; - int mnt_passno; -}; - -static inline FILE *setmntent (const char *file, const char *mode) -{ - return (FILE *) 1; -} - -static inline struct mntent *getmntent (FILE *stream) -{ - static struct mntent mntent = { - .mnt_dir = "/sys", - .mnt_type = "sysfs" - }; - - return &mntent; -} - -static inline int endmntent (FILE *stream) -{ - return 0; -} - -#endif /* _MNTENT_H */ -#endif /* __KLIBC__ */ diff --git a/libsysfs/dlist.c b/libsysfs/dlist.c index c4ee3245..c44e9d5f 100644 --- a/libsysfs/dlist.c +++ b/libsysfs/dlist.c @@ -27,6 +27,7 @@ * delete function. Otherwise dlist will just use free. */ +#include "stdlib.h" #include "dlist.h" /* diff --git a/libsysfs/dlist.h b/libsysfs/dlist.h index 9e3a6c96..62eaa9fe 100644 --- a/libsysfs/dlist.h +++ b/libsysfs/dlist.h @@ -50,9 +50,10 @@ * Just use the dlist_(insert|delete)_(before|after) macros if you do not want * to think about it. - */ -#include + +#include + typedef struct dl_node { struct dl_node *prev; struct dl_node *next; diff --git a/libsysfs/sysfs.h b/libsysfs/sysfs.h index 30bd9b40..83842779 100644 --- a/libsysfs/sysfs.h +++ b/libsysfs/sysfs.h @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include -- 2.39.5