diff options
author | hut <hut@lavabit.com> | 2010-05-14 18:43:28 +0200 |
---|---|---|
committer | hut <hut@lavabit.com> | 2010-05-14 18:43:28 +0200 |
commit | 298c72a273d440c0cd0b3a3611ddee0584e17df2 (patch) | |
tree | 7e0b6120fa757848a12897148ae580d8dab322cc | |
parent | 863f85ce9000eaef047631db0e42cdbfbb7c776e (diff) | |
download | ranger-298c72a273d440c0cd0b3a3611ddee0584e17df2.tar.gz |
fsobject.fsobject: corrected typo and optimized loop
-rw-r--r-- | ranger/fsobject/fsobject.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ranger/fsobject/fsobject.py b/ranger/fsobject/fsobject.py index 63ff85ce..e9c44653 100644 --- a/ranger/fsobject/fsobject.py +++ b/ranger/fsobject/fsobject.py @@ -260,13 +260,13 @@ class FileSystemObject(MimeTypeAware, FileManagerAware): mode = self.stat.st_mode test = 0o0400 - for who in range(3): + while test: for what in "rwx": if mode & test: perms.append(what) else: perms.append('-') - test >> 1 + test >>= 1 self.permissions = ''.join(perms) return self.permissions |