Browse code

Don't stop on decoding errors

Hanno Böck authored on25/11/2019 09:22:47
Showing1 changed files
... ...
@@ -174,7 +174,7 @@ for fdir in args:
174 174
                 if filename == item['file']:
175 175
                     mfile = os.path.join(root, filename)
176 176
                     try:
177
-                        file = open(mfile)
177
+                        file = open(mfile, errors='replace')
178 178
                     except Exception:
179 179
                         continue
180 180
                     filestr = file.read()