1
0
mirror of synced 2026-01-20 17:38:02 +00:00

Use rmtree not rmdir

rmdir does not remove dir when not empty. Use rmtree for that.
makes t/xen-delete-image test pass.
This commit is contained in:
Stéphane Jourdois 2010-07-11 14:40:02 +02:00 committed by Axel Beckert
parent a262d30b1a
commit 14846e85fd

View File

@ -156,6 +156,7 @@ use strict;
use English;
use Getopt::Long;
use Pod::Usage;
use File::Path;
#
@ -517,7 +518,7 @@ sub deleteXenImage
print "Would delete: $prefix$hostname\n";
} else {
print "Removing: " . $prefix . $hostname . "\n";
rmdir( $prefix . $hostname );
rmtree( $prefix . $hostname );
}
}
}