Age | Commit message (Collapse) | Author |
|
If it's needed, there has to be a comment why. There isn't.
function old new delta
.rodata 103686 103669 -17
remove_file 598 571 -27
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 0/2 up/down: 0/-44) Total: -44 bytes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
When deleting a directory, the directory should not be removed if the
file in the subdirectory fails to be deleted.
Background information:
When I tested the kernel using LTP (linux-test-project).I found the
mv command have some issue. The LTP test case use the mv command to
move the directory t1 in the cgroup file system to the /tmp directory.
becase files in the cgroup file system are not allowed to be removed.
so the mv reported "Permission denied", but I used the ls command to
view the results and found that the directory t1 had been removed
from the cgroup file system. For the same test case, I used the mv
tool in the GNU coreutils, and the directory t1 will not be removed.
the following testcase use busybox mv:
/ # mount -t cgroup -o cpu cgroup /cpu
/ # cd /cpu
/cpu # mkdir -p t1
/cpu # ls
cgroup.clone_children cpu.cfs_period_us cpu.stat t1
cgroup.procs cpu.cfs_quota_us notify_on_release tasks
cgroup.sane_behavior cpu.shares release_agent
/cpu # mv t1 /tmp
mv: can't remove 't1/cgroup.procs': Operation not permitted
mv: can't remove 't1/cpu.cfs_period_us': Operation not permitted
mv: can't remove 't1/cpu.stat': Operation not permitted
mv: can't remove 't1/cpu.shares': Operation not permitted
mv: can't remove 't1/cpu.cfs_quota_us': Operation not permitted
mv: can't remove 't1/tasks': Operation not permitted
mv: can't remove 't1/notify_on_release': Operation not permitted
mv: can't remove 't1/cgroup.clone_children': Operation not permitted
/cpu # ls
cgroup.clone_children cpu.cfs_period_us cpu.stat cgroup.procs
cpu.cfs_quota_us notify_on_release tasks cgroup.sane_behavior
cpu.shares release_agent
/cpu #
This patch fixed it, don't call rmdir if remove_file return failure,
and under certain file systems, the mv could work normally.
Signed-off-by: Chen Yu <yu.chen3@zte.com.cn>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
function old new delta
bb_ask_y_confirmation_FILE - 83 +83
inetd_main 2033 2043 +10
udhcp_send_kernel_packet 295 301 +6
rmescapes 306 310 +4
send_tree 353 355 +2
i2cdetect_main 674 672 -2
confirm_or_abort 43 38 -5
get_terminal_width_height 242 234 -8
bb_ask_y_confirmation 76 10 -66
xargs_main 823 755 -68
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 4/5 up/down: 105/-149) Total: -44 bytes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
bb_ask_y_confirmation
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
With FEATURE_VERBOSE off, practically no size change.
With it on:
function old new delta
remove_file 493 556 +63
install_main 719 765 +46
bb_make_directory 383 419 +36
rmdir_main 162 191 +29
copy_file 1516 1544 +28
mv_main 502 525 +23
cmp_main 677 693 +16
bbconfig_config_bz2 5264 5279 +15
mkdir_main 158 168 +10
install_longopts 66 76 +10
rm_main 167 175 +8
nexpr 840 846 +6
scan_tree 275 280 +5
fsck_main 1807 1811 +4
ed_main 2541 2545 +4
expand_one_var 1574 1575 +1
swap_on_off_main 420 418 -2
parse_command 1443 1440 -3
redirect 1279 1274 -5
do_load 946 918 -28
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 16/4 up/down: 304/-38) Total: 266 bytes
Based on the patch by Igor Živković.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
function old new delta
ln_main 445 524 +79
packed_usage 29182 29179 -3
Signed-off-by: Simon B <sburnet@hotmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
This change retains "or later" state! No licensing _changes_ here,
only form is adjusted (article, space between "GPL" and "v2" and so on).
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
text data bss dec hex filename
808035 611 6868 815514 c719a busybox_old
804472 611 6868 811951 c63af busybox_unstripped
|
|
|
|
Put big scary warnings in relevant places.
|
|
|
|
|
|
|
|
things like xasprintf() into xfuncs.c, remove xprint_file_by_name() (it only
had one user), clean up lots of #includes... General cleanup pass. What I've
been doing for the last couple days.
And it conflicts! I've removed httpd.c from this checkin due to somebody else
touching that file. It builds for me. I have to catch a bus. (Now you know
why I'm looking forward to Mercurial.)
|
|
text data bss dec hex filename
889445 9392 1035784 1934621 1d851d busybox.gcc-4.2.orig
889297 9392 1035784 1934473 1d8489 busybox.gcc-4.2
889009 9820 1037860 1936689 1d8d31 busybox.gcc-4.1.orig
888817 9820 1037860 1936497 1d8c71 busybox.gcc-4.1
|
|
definitions. (That should only be on prototypes.)
|
|
|
|
|
|
-Erik
|
|
Config.h and using gcc's -fno-builtin. There are probably other files
with the similar problems.
Also, if building against uClibc, don't include asm/unistd.h in syscalls.c
and module_syscalls.c.
|
|
|
|
|