Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@sugarlabs.org>2009-03-01 17:24:12 (GMT)
committer Tomeu Vizoso <tomeu@sugarlabs.org>2009-03-01 17:24:12 (GMT)
commitd22b52434bc37d8f921a4f5de8018bc9962a1105 (patch)
tree2ce6af8c69c4aa51477bb3c90dc92254d53f82cc /src
parent50a253b1b9974ff7c5b392f9d30917b049cf1aa8 (diff)
Don't recursively clean an activity if it's a symbolic link #444
Diffstat (limited to 'src')
-rw-r--r--src/sugar/bundle/activitybundle.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/sugar/bundle/activitybundle.py b/src/sugar/bundle/activitybundle.py
index 7050456..268576e 100644
--- a/src/sugar/bundle/activitybundle.py
+++ b/src/sugar/bundle/activitybundle.py
@@ -350,6 +350,12 @@ class ActivityBundle(Bundle):
return install_path
def uninstall(self, install_path, force=False):
+ if os.path.islink(install_path):
+ # Don't remove the actual activity dir if it's a symbolic link
+ # because we may be removing user data.
+ os.unlink(install_path)
+ return
+
xdg_data_home = os.getenv('XDG_DATA_HOME',
os.path.expanduser('~/.local/share'))