diff options
author | "Robert P. J. Day" <rpjday@mindspring.com> | 2006-07-01 15:09:17 +0000 |
---|---|---|
committer | "Robert P. J. Day" <rpjday@mindspring.com> | 2006-07-01 15:09:17 +0000 |
commit | 7ccb65f3a4f5c84d010978d450df57d3c1b13297 (patch) | |
tree | 1a8ad50d798ce0a176c20b817d53ffaead21b14c | |
parent | d35ef0f66643f2bc43bd7070df0356e0b064b755 (diff) | |
download | busybox-w32-7ccb65f3a4f5c84d010978d450df57d3c1b13297.tar.gz busybox-w32-7ccb65f3a4f5c84d010978d450df57d3c1b13297.tar.bz2 busybox-w32-7ccb65f3a4f5c84d010978d450df57d3c1b13297.zip |
Yet more "#if 0" content removed.
-rw-r--r-- | e2fsprogs/blkid/read.c | 25 | ||||
-rw-r--r-- | e2fsprogs/ext2fs/closefs.c | 4 | ||||
-rw-r--r-- | e2fsprogs/ext2fs/icount.c | 14 | ||||
-rw-r--r-- | e2fsprogs/ext2fs/inode.c | 21 | ||||
-rw-r--r-- | e2fsprogs/fsck.c | 9 | ||||
-rw-r--r-- | e2fsprogs/mke2fs.c | 3 | ||||
-rw-r--r-- | e2fsprogs/util.c | 7 | ||||
-rwxr-xr-x | scripts/objsizes | 3 |
8 files changed, 1 insertions, 85 deletions
diff --git a/e2fsprogs/blkid/read.c b/e2fsprogs/blkid/read.c index 5f7422b0c..a2a8bb59e 100644 --- a/e2fsprogs/blkid/read.c +++ b/e2fsprogs/blkid/read.c | |||
@@ -98,31 +98,6 @@ static char *strip_line(char *line) | |||
98 | return line; | 98 | return line; |
99 | } | 99 | } |
100 | 100 | ||
101 | #if 0 | ||
102 | static char *parse_word(char **buf) | ||
103 | { | ||
104 | char *word, *next; | ||
105 | |||
106 | word = *buf; | ||
107 | if (*word == '\0') | ||
108 | return NULL; | ||
109 | |||
110 | word = skip_over_blank(word); | ||
111 | next = skip_over_word(word); | ||
112 | if (*next) { | ||
113 | char *end = next - 1; | ||
114 | if (*end == '"' || *end == '\'') | ||
115 | *end = '\0'; | ||
116 | *next++ = '\0'; | ||
117 | } | ||
118 | *buf = next; | ||
119 | |||
120 | if (*word == '"' || *word == '\'') | ||
121 | word++; | ||
122 | return word; | ||
123 | } | ||
124 | #endif | ||
125 | |||
126 | /* | 101 | /* |
127 | * Start parsing a new line from the cache. | 102 | * Start parsing a new line from the cache. |
128 | * | 103 | * |
diff --git a/e2fsprogs/ext2fs/closefs.c b/e2fsprogs/ext2fs/closefs.c index 481d1c575..40a697496 100644 --- a/e2fsprogs/ext2fs/closefs.c +++ b/e2fsprogs/ext2fs/closefs.c | |||
@@ -151,10 +151,6 @@ static errcode_t write_primary_superblock(ext2_filsys fs, | |||
151 | if (old_super[check_idx] == new_super[check_idx]) | 151 | if (old_super[check_idx] == new_super[check_idx]) |
152 | break; | 152 | break; |
153 | size = 2 * (check_idx - write_idx); | 153 | size = 2 * (check_idx - write_idx); |
154 | #if 0 | ||
155 | printf("Writing %d bytes starting at %d\n", | ||
156 | size, write_idx*2); | ||
157 | #endif | ||
158 | retval = io_channel_write_byte(fs->io, | 154 | retval = io_channel_write_byte(fs->io, |
159 | SUPERBLOCK_OFFSET + (2 * write_idx), size, | 155 | SUPERBLOCK_OFFSET + (2 * write_idx), size, |
160 | new_super + write_idx); | 156 | new_super + write_idx); |
diff --git a/e2fsprogs/ext2fs/icount.c b/e2fsprogs/ext2fs/icount.c index 7ae2a5c0f..7d0d63c91 100644 --- a/e2fsprogs/ext2fs/icount.c +++ b/e2fsprogs/ext2fs/icount.c | |||
@@ -112,10 +112,6 @@ errcode_t ext2fs_create_icount2(ext2_filsys fs, int flags, unsigned int size, | |||
112 | } | 112 | } |
113 | 113 | ||
114 | bytes = (size_t) (icount->size * sizeof(struct ext2_icount_el)); | 114 | bytes = (size_t) (icount->size * sizeof(struct ext2_icount_el)); |
115 | #if 0 | ||
116 | printf("Icount allocated %d entries, %d bytes.\n", | ||
117 | icount->size, bytes); | ||
118 | #endif | ||
119 | retval = ext2fs_get_mem(bytes, &icount->list); | 115 | retval = ext2fs_get_mem(bytes, &icount->list); |
120 | if (retval) | 116 | if (retval) |
121 | goto errout; | 117 | goto errout; |
@@ -172,9 +168,6 @@ static struct ext2_icount_el *insert_icount_el(ext2_icount_t icount, | |||
172 | } | 168 | } |
173 | if (new_size < (icount->size + 100)) | 169 | if (new_size < (icount->size + 100)) |
174 | new_size = icount->size + 100; | 170 | new_size = icount->size + 100; |
175 | #if 0 | ||
176 | printf("Reallocating icount %d entries...\n", new_size); | ||
177 | #endif | ||
178 | retval = ext2fs_resize_mem((size_t) icount->size * | 171 | retval = ext2fs_resize_mem((size_t) icount->size * |
179 | sizeof(struct ext2_icount_el), | 172 | sizeof(struct ext2_icount_el), |
180 | (size_t) new_size * | 173 | (size_t) new_size * |
@@ -224,15 +217,9 @@ static struct ext2_icount_el *get_icount_el(ext2_icount_t icount, | |||
224 | icount->cursor = 0; | 217 | icount->cursor = 0; |
225 | if (ino == icount->list[icount->cursor].ino) | 218 | if (ino == icount->list[icount->cursor].ino) |
226 | return &icount->list[icount->cursor++]; | 219 | return &icount->list[icount->cursor++]; |
227 | #if 0 | ||
228 | printf("Non-cursor get_icount_el: %u\n", ino); | ||
229 | #endif | ||
230 | low = 0; | 220 | low = 0; |
231 | high = (int) icount->count-1; | 221 | high = (int) icount->count-1; |
232 | while (low <= high) { | 222 | while (low <= high) { |
233 | #if 0 | ||
234 | mid = (low+high)/2; | ||
235 | #else | ||
236 | if (low == high) | 223 | if (low == high) |
237 | mid = low; | 224 | mid = low; |
238 | else { | 225 | else { |
@@ -249,7 +236,6 @@ static struct ext2_icount_el *get_icount_el(ext2_icount_t icount, | |||
249 | (highval - lowval); | 236 | (highval - lowval); |
250 | mid = low + ((int) (range * (high-low))); | 237 | mid = low + ((int) (range * (high-low))); |
251 | } | 238 | } |
252 | #endif | ||
253 | if (ino == icount->list[mid].ino) { | 239 | if (ino == icount->list[mid].ino) { |
254 | icount->cursor = mid+1; | 240 | icount->cursor = mid+1; |
255 | return &icount->list[mid]; | 241 | return &icount->list[mid]; |
diff --git a/e2fsprogs/ext2fs/inode.c b/e2fsprogs/ext2fs/inode.c index 8608dc88b..88da4e02e 100644 --- a/e2fsprogs/ext2fs/inode.c +++ b/e2fsprogs/ext2fs/inode.c | |||
@@ -355,27 +355,6 @@ static errcode_t get_next_blocks(ext2_inode_scan scan) | |||
355 | return 0; | 355 | return 0; |
356 | } | 356 | } |
357 | 357 | ||
358 | #if 0 | ||
359 | /* | ||
360 | * Returns 1 if the entire inode_buffer has a non-zero size and | ||
361 | * contains all zeros. (Not just deleted inodes, since that means | ||
362 | * that part of the inode table was used at one point; we want all | ||
363 | * zeros, which means that the inode table is pristine.) | ||
364 | */ | ||
365 | static inline int is_empty_scan(ext2_inode_scan scan) | ||
366 | { | ||
367 | int i; | ||
368 | |||
369 | if (scan->bytes_left == 0) | ||
370 | return 0; | ||
371 | |||
372 | for (i=0; i < scan->bytes_left; i++) | ||
373 | if (scan->ptr[i]) | ||
374 | return 0; | ||
375 | return 1; | ||
376 | } | ||
377 | #endif | ||
378 | |||
379 | errcode_t ext2fs_get_next_inode_full(ext2_inode_scan scan, ext2_ino_t *ino, | 358 | errcode_t ext2fs_get_next_inode_full(ext2_inode_scan scan, ext2_ino_t *ino, |
380 | struct ext2_inode *inode, int bufsize) | 359 | struct ext2_inode *inode, int bufsize) |
381 | { | 360 | { |
diff --git a/e2fsprogs/fsck.c b/e2fsprogs/fsck.c index adf34c44d..54e8597d4 100644 --- a/e2fsprogs/fsck.c +++ b/e2fsprogs/fsck.c | |||
@@ -135,12 +135,6 @@ static char *base_device(const char *device) | |||
135 | goto errout; | 135 | goto errout; |
136 | cp += 5; | 136 | cp += 5; |
137 | 137 | ||
138 | #if 0 /* this is for old stuff no one uses anymore ? */ | ||
139 | /* Skip over /dev/dsk/... */ | ||
140 | if (strncmp(cp, "dsk/", 4) == 0) | ||
141 | cp += 4; | ||
142 | #endif | ||
143 | |||
144 | /* | 138 | /* |
145 | * For md devices, we treat them all as if they were all | 139 | * For md devices, we treat them all as if they were all |
146 | * on one disk, since we don't know how to parallelize them. | 140 | * on one disk, since we don't know how to parallelize them. |
@@ -918,9 +912,6 @@ static void compile_fs_type(char *fs_type, struct fs_type_compile *cmp) | |||
918 | bb_error_msg_and_die("%s", fs_type_syntax_error); | 912 | bb_error_msg_and_die("%s", fs_type_syntax_error); |
919 | } | 913 | } |
920 | } | 914 | } |
921 | #if 0 | ||
922 | printf("Adding %s to list (type %d).\n", s, cmp->type[num]); | ||
923 | #endif | ||
924 | cmp->list[num++] = string_copy(s); | 915 | cmp->list[num++] = string_copy(s); |
925 | s = strtok(NULL, ","); | 916 | s = strtok(NULL, ","); |
926 | } | 917 | } |
diff --git a/e2fsprogs/mke2fs.c b/e2fsprogs/mke2fs.c index 0ecbd0551..22e4d2578 100644 --- a/e2fsprogs/mke2fs.c +++ b/e2fsprogs/mke2fs.c | |||
@@ -828,9 +828,6 @@ static int PRS(int argc, char *argv[]) | |||
828 | param.s_rev_level = 1; /* Create revision 1 filesystems now */ | 828 | param.s_rev_level = 1; /* Create revision 1 filesystems now */ |
829 | param.s_feature_incompat |= EXT2_FEATURE_INCOMPAT_FILETYPE; | 829 | param.s_feature_incompat |= EXT2_FEATURE_INCOMPAT_FILETYPE; |
830 | param.s_feature_ro_compat |= EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER; | 830 | param.s_feature_ro_compat |= EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER; |
831 | #if 0 | ||
832 | param.s_feature_compat |= EXT2_FEATURE_COMPAT_DIR_INDEX; | ||
833 | #endif | ||
834 | 831 | ||
835 | #ifdef __linux__ | 832 | #ifdef __linux__ |
836 | linux_version_code = get_linux_version_code(); | 833 | linux_version_code = get_linux_version_code(); |
diff --git a/e2fsprogs/util.c b/e2fsprogs/util.c index 537021df7..151af3211 100644 --- a/e2fsprogs/util.c +++ b/e2fsprogs/util.c | |||
@@ -110,14 +110,7 @@ void parse_journal_opts(char **journal_device, int *journal_flags, | |||
110 | { | 110 | { |
111 | char *buf, *token, *next, *p, *arg; | 111 | char *buf, *token, *next, *p, *arg; |
112 | int journal_usage = 0; | 112 | int journal_usage = 0; |
113 | #if 0 | ||
114 | int len; | ||
115 | len = strlen(opts); | ||
116 | buf = xmalloc(len+1); | ||
117 | strcpy(buf, opts); | ||
118 | #else | ||
119 | buf = bb_xstrdup(opts); | 113 | buf = bb_xstrdup(opts); |
120 | #endif | ||
121 | for (token = buf; token && *token; token = next) { | 114 | for (token = buf; token && *token; token = next) { |
122 | p = strchr(token, ','); | 115 | p = strchr(token, ','); |
123 | next = 0; | 116 | next = 0; |
diff --git a/scripts/objsizes b/scripts/objsizes index 291285f03..ec9928238 100755 --- a/scripts/objsizes +++ b/scripts/objsizes | |||
@@ -4,5 +4,4 @@ printf "%9s %11s %9s %9s %s\n" "text+data" text+rodata rwdata bss filename | |||
4 | find -name '*.o' | sed 's:^\./::' | xargs size | grep '^ *[0-9]' \ | 4 | find -name '*.o' | sed 's:^\./::' | xargs size | grep '^ *[0-9]' \ |
5 | | while read text data bss dec hex filename; do | 5 | | while read text data bss dec hex filename; do |
6 | printf "%9d %11d %9d %9d %s\n" $((text+data)) $text $data $bss "$filename" | 6 | printf "%9d %11d %9d %9d %s\n" $((text+data)) $text $data $bss "$filename" |
7 | done \ | 7 | done |
8 | | sort | ||