summaryrefslogtreecommitdiffstats
path: root/move/make_live_tree_boot
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2003-10-30 11:14:11 +0000
committerPascal Rigaux <pixel@mandriva.com>2003-10-30 11:14:11 +0000
commitf8da93908fabc09e770a0a4b282e0d0cf4802e8f (patch)
tree050cbd1caab1e6fc05f0edb38c0630543c872baf /move/make_live_tree_boot
parent3517639ec3af9a6480137c3b54bbc99cf6cbccad (diff)
downloaddrakx-f8da93908fabc09e770a0a4b282e0d0cf4802e8f.tar
drakx-f8da93908fabc09e770a0a4b282e0d0cf4802e8f.tar.gz
drakx-f8da93908fabc09e770a0a4b282e0d0cf4802e8f.tar.bz2
drakx-f8da93908fabc09e770a0a4b282e0d0cf4802e8f.tar.xz
drakx-f8da93908fabc09e770a0a4b282e0d0cf4802e8f.zip
better list obtained using patched nfsd instead of Strace
Diffstat (limited to 'move/make_live_tree_boot')
-rwxr-xr-xmove/make_live_tree_boot5
1 files changed, 4 insertions, 1 deletions
diff --git a/move/make_live_tree_boot b/move/make_live_tree_boot
index 209631472..a6dc47721 100755
--- a/move/make_live_tree_boot
+++ b/move/make_live_tree_boot
@@ -19,7 +19,7 @@ if (@ARGV && $ARGV[0] eq '-u') {
if (-e $dest && -s $dest != -s $orig) {
warn "ERROR: $dest already exist, skipping\n";
- } else {
+ } elsif (!-d $dest || -l $dest) {
unlink $dest or die "removing $dest failed: $!\n";
rename $orig, $dest or die "moving $orig to $dest failed: $!\n";
}
@@ -27,6 +27,9 @@ if (@ARGV && $ARGV[0] eq '-u') {
rmdir($_) foreach reverse(chomp_(`find $boot_prefix -type d`));
if (-e $boot_prefix) {
+ print "still there:\n";
+ system('find', $boot_prefix);
+
foreach my $dest (chomp_(`find $prefix -type l`)) {
my $orig = readlink($dest) or next;
$orig =~ s!/image_boot/!$boot_prefix/! or next;