Permalink
Browse files

Rescue uid/gid lookup

  • Loading branch information...
1 parent ed1356b commit 44a5b6261fd95724600bca39e23e6b78ed792c3e @chneukirchen committed Mar 3, 2010
Showing with 2 additions and 2 deletions.
  1. +2 −2 colfm.rb
View
@@ -341,11 +341,11 @@ def modestring
end
def user
- Etc.getpwuid(@lstat.uid).name
+ Etc.getpwuid(@lstat.uid).name rescue @lstat.uid.to_s
end
def group
- Etc.getgrgid(@lstat.gid).name
+ Etc.getgrgid(@lstat.gid).name rescue @lstat.gid.to_s
end
# Inspired by busybox.

0 comments on commit 44a5b62

Please sign in to comment.