projects
/
nmutil.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1ad8942
)
stop possibility of infinite recursion in stages which
author
Luke Kenneth Casson Leighton
<lkcl@lkcl.net>
Wed, 11 May 2022 10:17:16 +0000
(11:17 +0100)
committer
Luke Kenneth Casson Leighton
<lkcl@lkcl.net>
Wed, 11 May 2022 10:17:19 +0000
(11:17 +0100)
set "stage = self"
src/nmutil/stageapi.py
patch
|
blob
|
history
diff --git
a/src/nmutil/stageapi.py
b/src/nmutil/stageapi.py
index 01fc568b0146d2502321441619a667438d1aaa7a..a34dc7e213e784c1f1d5518e62400ce2956618fa 100644
(file)
--- a/
src/nmutil/stageapi.py
+++ b/
src/nmutil/stageapi.py
@@
-197,7
+197,8
@@
class StageHelper(Stage):
def setup(self, m, i):
if self.stage is not None and hasattr(self.stage, "setup"):
- self.stage.setup(m, i)
+ if self.stage is not self: # stop infinite recursion
+ self.stage.setup(m, i)
def _postprocess(self, i): # XXX DISABLED
return i # RETURNS INPUT