diff options
Diffstat (limited to 'libbb/find_root_device.c')
-rw-r--r-- | libbb/find_root_device.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/libbb/find_root_device.c b/libbb/find_root_device.c index 675f8d2f5..71b79b8d0 100644 --- a/libbb/find_root_device.c +++ b/libbb/find_root_device.c | |||
@@ -7,11 +7,6 @@ | |||
7 | * Licensed under GPLv2 or later, see file LICENSE in this tarball for details. | 7 | * Licensed under GPLv2 or later, see file LICENSE in this tarball for details. |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <limits.h> | ||
11 | #include <stdio.h> | ||
12 | #include <string.h> | ||
13 | #include <dirent.h> | ||
14 | #include <stdlib.h> | ||
15 | #include "libbb.h" | 10 | #include "libbb.h" |
16 | 11 | ||
17 | char *find_block_device(char *path) | 12 | char *find_block_device(char *path) |
@@ -28,7 +23,7 @@ char *find_block_device(char *path) | |||
28 | char devpath[PATH_MAX]; | 23 | char devpath[PATH_MAX]; |
29 | sprintf(devpath,"/dev/%s", entry->d_name); | 24 | sprintf(devpath,"/dev/%s", entry->d_name); |
30 | if(!stat(devpath, &st) && S_ISBLK(st.st_mode) && st.st_rdev == dev) { | 25 | if(!stat(devpath, &st) && S_ISBLK(st.st_mode) && st.st_rdev == dev) { |
31 | retpath = bb_xstrdup(devpath); | 26 | retpath = xstrdup(devpath); |
32 | break; | 27 | break; |
33 | } | 28 | } |
34 | } | 29 | } |