diff options
author | Narayan Desai <desai@mcs.anl.gov> | 2009-06-14 19:52:46 +0000 |
---|---|---|
committer | Narayan Desai <desai@mcs.anl.gov> | 2009-06-14 19:52:46 +0000 |
commit | 4afa9bbe3d00ec997dd255d1d93e5ce5e13d5b2a (patch) | |
tree | a76b3b63f7745ebf1bb8a01f402fc59e859011a9 /src/lib/Client | |
parent | 084828ef29ab87db18831ff8cbfd88ed744c082f (diff) | |
download | bcfg2-4afa9bbe3d00ec997dd255d1d93e5ce5e13d5b2a.tar.gz bcfg2-4afa9bbe3d00ec997dd255d1d93e5ce5e13d5b2a.tar.bz2 bcfg2-4afa9bbe3d00ec997dd255d1d93e5ce5e13d5b2a.zip |
Improve error message for attempted directory unlinks (Patch from Torsten Rehn) (Resolves Ticket #657)
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5277 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Client')
-rw-r--r-- | src/lib/Client/Tools/POSIX.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lib/Client/Tools/POSIX.py b/src/lib/Client/Tools/POSIX.py index e57ee96b6..0ad9dacf6 100644 --- a/src/lib/Client/Tools/POSIX.py +++ b/src/lib/Client/Tools/POSIX.py @@ -279,6 +279,9 @@ class POSIX(Bcfg2.Client.Tools.Tool): if entry.get('prune', 'false') == 'true' and entry.get("qtest"): for pname in entry.get("qtest").split(":"): ulfailed = False + if os.path.isdir(pname): + self.logger.info("Not removing extra directory %s, please check and remove manually" % pname) + continue try: self.logger.debug("Unlinking file %s" % pname) os.unlink(pname) |