Skip to content

Commit 61f70af

Browse files
authored
CtorEval Fuzzer: Generalize export regex (#5778)
Just look for export names as "" with some other stuff in the middle. Missing from the old regex: spaces, parens, and probably more. Spaces and parens are used in the test suite, which is how this was noticed by the fuzzer.
1 parent 7aeaf13 commit 61f70af

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/fuzz_opt.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1263,7 +1263,7 @@ def handle(self, wasm):
12631263

12641264
# get the list of exports, so we can tell ctor-eval what to eval.
12651265
wat = run([in_bin('wasm-dis'), wasm] + FEATURE_OPTS)
1266-
p = re.compile(r'^ [(]export "([\d\w$+-_:.]+)" [(]func')
1266+
p = re.compile(r'^ [(]export "(.*[^\\]?)" [(]func')
12671267
exports = []
12681268
for line in wat.splitlines():
12691269
m = p.match(line)

0 commit comments

Comments
 (0)