summaryrefslogtreecommitdiff
path: root/python/stringrecognizer.py
diff options
context:
space:
mode:
authorJosh Ferrell <josh@vector35.com>2026-04-15 11:21:40 -0400
committerJosh Ferrell <josh@vector35.com>2026-04-15 11:21:44 -0400
commitb4ccb82ea76b98457d9dc59424632ca412511ed4 (patch)
tree2eb4d7875181cee7b05413fa6dcdaea3a1d95981 /python/stringrecognizer.py
parentc08cf3f1eaa73a5171c27044100479998104d58a (diff)
[Python API] Replace bare "except:" with "except Exception:" to fix signal propagation
Diffstat (limited to 'python/stringrecognizer.py')
-rw-r--r--python/stringrecognizer.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/python/stringrecognizer.py b/python/stringrecognizer.py
index ad97414d..055e236d 100644
--- a/python/stringrecognizer.py
+++ b/python/stringrecognizer.py
@@ -203,7 +203,7 @@ class StringRecognizer(metaclass=_StringRecognizerMetaClass):
hlil = highlevelil.HighLevelILFunction(handle=core.BNNewHighLevelILFunctionReference(hlil))
type = types.Type.create(handle=core.BNNewTypeReference(type))
return self.is_valid_for_type(hlil, type)
- except:
+ except Exception:
log_error_for_exception("Unhandled Python exception in StringRecognizer._is_valid_for_type")
return False
@@ -217,7 +217,7 @@ class StringRecognizer(metaclass=_StringRecognizerMetaClass):
return False
result[0] = ref._to_core_struct(True)
return True
- except:
+ except Exception:
log_error_for_exception("Unhandled Python exception in StringRecognizer._recognize_constant")
return False
@@ -231,7 +231,7 @@ class StringRecognizer(metaclass=_StringRecognizerMetaClass):
return False
result[0] = ref._to_core_struct(True)
return True
- except:
+ except Exception:
log_error_for_exception("Unhandled Python exception in StringRecognizer._recognize_constant_pointer")
return False
@@ -245,7 +245,7 @@ class StringRecognizer(metaclass=_StringRecognizerMetaClass):
return False
result[0] = ref._to_core_struct(True)
return True
- except:
+ except Exception:
log_error_for_exception("Unhandled Python exception in StringRecognizer._recognize_extern_pointer")
return False
@@ -259,7 +259,7 @@ class StringRecognizer(metaclass=_StringRecognizerMetaClass):
return False
result[0] = ref._to_core_struct(True)
return True
- except:
+ except Exception:
log_error_for_exception("Unhandled Python exception in StringRecognizer._recognize_import")
return False