diff options
Diffstat (limited to 'util-linux')
| -rw-r--r-- | util-linux/mount.c | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c index f8ae1df19..35665a2b5 100644 --- a/util-linux/mount.c +++ b/util-linux/mount.c | |||
| @@ -31,6 +31,20 @@ | |||
| 31 | #include <rpc/pmap_clnt.h> | 31 | #include <rpc/pmap_clnt.h> |
| 32 | 32 | ||
| 33 | 33 | ||
| 34 | #if defined(__dietlibc__) | ||
| 35 | /* 16.12.2006, Sampo Kellomaki (sampo@iki.fi) | ||
| 36 | * dietlibc-0.30 does not have implementation of getmntent_r() */ | ||
| 37 | /* OTOH: why we use getmntent_r instead of getmntent? TODO... */ | ||
| 38 | struct mntent *getmntent_r(FILE* stream, struct mntent* result, char* buffer, int bufsize) | ||
| 39 | { | ||
| 40 | /* *** XXX FIXME WARNING: This hack is NOT thread safe. --Sampo */ | ||
| 41 | struct mntent* ment = getmntent(stream); | ||
| 42 | memcpy(result, ment, sizeof(struct mntent)); | ||
| 43 | return result; | ||
| 44 | } | ||
| 45 | #endif | ||
| 46 | |||
| 47 | |||
| 34 | // Not real flags, but we want to be able to check for this. | 48 | // Not real flags, but we want to be able to check for this. |
| 35 | enum { | 49 | enum { |
| 36 | MOUNT_USERS = (1<<28)*ENABLE_DESKTOP, | 50 | MOUNT_USERS = (1<<28)*ENABLE_DESKTOP, |
| @@ -1564,7 +1578,8 @@ int mount_main(int argc, char **argv) | |||
| 1564 | sizeof(bb_common_bufsiz1))) | 1578 | sizeof(bb_common_bufsiz1))) |
| 1565 | { | 1579 | { |
| 1566 | // Don't show rootfs. FIXME: why?? | 1580 | // Don't show rootfs. FIXME: why?? |
| 1567 | if (!strcmp(mtpair->mnt_fsname, "rootfs")) continue; | 1581 | // util-linux 2.12a happily shows rootfs... |
| 1582 | //if (!strcmp(mtpair->mnt_fsname, "rootfs")) continue; | ||
| 1568 | 1583 | ||
| 1569 | if (!fstype || !strcmp(mtpair->mnt_type, fstype)) | 1584 | if (!fstype || !strcmp(mtpair->mnt_type, fstype)) |
| 1570 | printf("%s on %s type %s (%s)\n", mtpair->mnt_fsname, | 1585 | printf("%s on %s type %s (%s)\n", mtpair->mnt_fsname, |
