]> arthur.barton.de Git - bup.git/blobdiff - lib/cmd/index-cmd.py
index: fix bytes vs. str (py3) for --long output
[bup.git] / lib / cmd / index-cmd.py
index a479ca9427a7b768ef763aa0cdfe249091d96ace..fbaa0299f2d1eab9d7676ffcd1a0da128b6940dd 100755 (executable)
@@ -319,7 +319,8 @@ if opt['print'] or opt.status or opt.modified:
         if opt.hash:
             line += hexlify(ent.sha) + b' '
         if opt.long:
-            line += b'%7s %7s ' % (oct(ent.mode), oct(ent.gitmode))
+            line += b'%7s %7s ' % (oct(ent.mode).encode('ascii'),
+                                   oct(ent.gitmode).encode('ascii'))
         out.write(line + (name or b'./') + b'\n')
 
 if opt.check and (opt['print'] or opt.status or opt.modified or opt.update):