summaryrefslogtreecommitdiff
path: root/libsysfs/sysfs_utils.c
diff options
context:
space:
mode:
authorgreg@kroah.com <greg@kroah.com>2003-10-22 23:48:55 -0700
committerGreg KH <gregkh@suse.de>2005-04-26 21:06:22 -0700
commit1e959a4b05f93bf31d0603a027b50cb148ef7e90 (patch)
tree535e27110fb4f6359466cbbaf2bda0e0d00b84cc /libsysfs/sysfs_utils.c
parentc8ba857171bd09a0019d3182fe989c6cf06d98d2 (diff)
[PATCH] klibc specific tweaks
Diffstat (limited to 'libsysfs/sysfs_utils.c')
-rw-r--r--libsysfs/sysfs_utils.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libsysfs/sysfs_utils.c b/libsysfs/sysfs_utils.c
index 4475342433..f1303cacb3 100644
--- a/libsysfs/sysfs_utils.c
+++ b/libsysfs/sysfs_utils.c
@@ -22,6 +22,9 @@
*/
#include "libsysfs.h"
#include "sysfs.h"
+#ifndef __KLIBC__
+#include <mntent.h>
+#endif
/**
* sysfs_get_mnt_path: Gets the mount point for specified filesystem.
@@ -33,6 +36,10 @@
static int sysfs_get_fs_mnt_path(const unsigned char *fs_type,
unsigned char *mnt_path, size_t len)
{
+#ifdef __KLIBC__
+ strcpy(mnt_path, "/sys");
+ return 0;
+#else
FILE *mnt;
struct mntent *mntent;
int ret = 0;
@@ -66,6 +73,7 @@ static int sysfs_get_fs_mnt_path(const unsigned char *fs_type,
ret = -1;
}
return ret;
+#endif
}
/*