diff options
author | hut <hut@lavabit.com> | 2012-03-21 02:38:40 +0100 |
---|---|---|
committer | hut <hut@lavabit.com> | 2012-03-21 02:38:40 +0100 |
commit | 79c760d71f62889e85f55a5bc130a20667feb894 (patch) | |
tree | 7b1704d8e98360db49affc7912a37e3cea5e8a43 | |
parent | ae6f5730ab2fafd992cc1d2f9bbae72df16fbbf9 (diff) | |
download | ranger-79c760d71f62889e85f55a5bc130a20667feb894.tar.gz |
ext.rifle: filter out filenames containing null-byte
-rwxr-xr-x | ranger/ext/rifle.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ranger/ext/rifle.py b/ranger/ext/rifle.py index 0a0b15ac..ea2a489c 100755 --- a/ranger/ext/rifle.py +++ b/ranger/ext/rifle.py @@ -175,7 +175,8 @@ class Rifle(object): self._app_flags = squash_flags(self._app_flags) flags = self._app_flags - _filenames = "' '".join(f.replace("'", "'\\\''") for f in files) + _filenames = "' '".join(f.replace("'", "'\\\''") for f in files + if "\x00" not in f) command = "set -- '%s'" % _filenames + '\n' # Apply flags |