[gobject-introspection] Ignore errors caused by permissions in $HOME
- From: Johan Dahlin <johan src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gobject-introspection] Ignore errors caused by permissions in $HOME
- Date: Wed, 2 Dec 2009 12:51:08 +0000 (UTC)
commit 8486bc107587f3884306252c4d97cb2d55c6d8b6
Author: Josselin Mouette <joss malsain org>
Date: Wed Dec 2 10:50:29 2009 -0200
Ignore errors caused by permissions in $HOME
https://bugzilla.gnome.org/show_bug.cgi?id=596960
giscanner/cachestore.py | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/giscanner/cachestore.py b/giscanner/cachestore.py
index 9ecde26..e127dda 100644
--- a/giscanner/cachestore.py
+++ b/giscanner/cachestore.py
@@ -35,7 +35,10 @@ def _get_cachedir():
cachedir = os.path.join(homedir, '.cache')
if not os.path.exists(cachedir):
- os.mkdir(cachedir, 0755)
+ try:
+ os.mkdir(cachedir, 0755)
+ except OSError:
+ return None
scannerdir = os.path.join(cachedir, 'g-ir-scanner')
if not os.path.exists(scannerdir):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]