[Meego-distribution-tools] [MIC2][COMMIT] At some error cases there are broken symbolic links left in loop dir. os.exists returns false for symbolic links and those were not cleaned properly, using os.lexists.
Yi Yang
yi.y.yang at intel.com
Wed Dec 1 01:05:14 PST 2010
commit b4c6f3c99b1061e1977ce0ffb53ea511fb82fbee
Author: Marko Saukko <marko.saukko at cybercom.com>
Date: Mon Nov 29 18:01:56 2010 +0200
At some error cases there are broken symbolic links left in loop dir. os.exists returns false for symbolic links and those were not cleaned properly, using os.lexists.
diff --git a/mic/appcreate/partitionedfs.py b/mic/appcreate/partitionedfs.py
index a642250..02f49c3 100644
--- a/mic/appcreate/partitionedfs.py
+++ b/mic/appcreate/partitionedfs.py
@@ -190,7 +190,7 @@ class PartitionedMount(Mount):
# to match their parent device + partition num
# kpartx doesn't work like this, so we add compat
# symlinks to point to /dev/mapper
- if os.path.exists(loopdev):
+ if os.path.lexists(loopdev):
os.unlink(loopdev)
os.symlink(mapperdev, loopdev)
More information about the MeeGo-distribution-tools
mailing list