mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Use except Exception where Py2/3 disagrees
This commit is contained in:
parent
d01648d637
commit
57eed5baa4
4 changed files with 6 additions and 6 deletions
|
@ -475,7 +475,7 @@ class MachCommands(CommandBase):
|
|||
if os.path.exists(crate_path):
|
||||
try:
|
||||
delete(crate_path)
|
||||
except (FileNotFoundError, PermissionError):
|
||||
except Exception:
|
||||
print(traceback.format_exc())
|
||||
print("Delete %s failed!" % crate_path)
|
||||
else:
|
||||
|
|
|
@ -920,7 +920,7 @@ def package_gstreamer_dlls(env, servo_exe_dir, target, uwp):
|
|||
for gst_lib in gst_dlls:
|
||||
try:
|
||||
shutil.copy(path.join(gst_root, "bin", gst_lib), servo_exe_dir)
|
||||
except FileNotFoundError:
|
||||
except Exception:
|
||||
missing += [str(gst_lib)]
|
||||
|
||||
for gst_lib in missing:
|
||||
|
@ -976,7 +976,7 @@ def package_gstreamer_dlls(env, servo_exe_dir, target, uwp):
|
|||
for gst_lib in gst_dlls:
|
||||
try:
|
||||
shutil.copy(path.join(gst_plugin_path, gst_lib), servo_exe_dir)
|
||||
except FileNotFoundError:
|
||||
except Exception:
|
||||
missing += [str(gst_lib)]
|
||||
|
||||
for gst_lib in missing:
|
||||
|
|
|
@ -537,7 +537,7 @@ class CommandBase(object):
|
|||
try:
|
||||
if check_gstreamer_lib():
|
||||
return False
|
||||
except (FileNotFoundError, WindowsError):
|
||||
except Exception:
|
||||
# Some systems don't have pkg-config; we can't probe in this case
|
||||
# and must hope for the best
|
||||
return False
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue