Prevent files being opened with '+' in the mode string. Fixes Issue 129

parent 1e7cddbc
......@@ -40,7 +40,7 @@ class ReadOnlyFS(WrapFS):
def open(self, path, mode='r', **kwargs):
""" Only permit read access """
if 'w' in mode or 'a' in mode:
if 'w' in mode or 'a' in mode or '+' in mode:
raise UnsupportedError('write')
return super(ReadOnlyFS, self).open(path, mode, **kwargs)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment