Skip to content
This repository has been archived by the owner on Aug 21, 2020. It is now read-only.

Commit

Permalink
Also try fallback mode on locking if permissions fail, fixes issue #50
Browse files Browse the repository at this point in the history
  • Loading branch information
simoncadman committed Mar 2, 2014
1 parent ddd00d5 commit 644af0a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion oauth2client/locked_file.py
Expand Up @@ -167,7 +167,7 @@ def open_and_lock(self, timeout, delay):
self._fh = open(self._filename, self._mode)
except IOError, e:
# If we can't access with _mode, try _fallback_mode and don't lock.
if e.errno == errno.EACCES:
if e.errno == errno.EACCES or e.errno == errno.EPERM:
self._fh = open(self._filename, self._fallback_mode)
return

Expand Down

0 comments on commit 644af0a

Please sign in to comment.