diff options
-rwxr-xr-x | emscripten.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/emscripten.py b/emscripten.py index aa47e4f1..217fd6d5 100755 --- a/emscripten.py +++ b/emscripten.py @@ -629,9 +629,10 @@ Runtime.stackRestore = function(top) { asm['stackRestore'](top) }; # Create symbol table for self-dlopen if settings.get('DLOPEN_SUPPORT'): - symbol_table = { k:v+forwarded_json['Runtime']['GLOBAL_BASE'] - for k,v in forwarded_json['Variables']['indexedGlobals'].iteritems() - if forwarded_json['Variables']['globals'][k]['named'] } + symbol_table = {} + for k, v in forwarded_json['Variables']['indexedGlobals'].iteritems(): + if forwarded_json['Variables']['globals'][k]['named']: + symbol_table[k] = v + forwarded_json['Runtime']['GLOBAL_BASE'] for raw in last_forwarded_json['Functions']['tables'].itervalues(): if raw == '': continue table = map(string.strip, raw[raw.find('[')+1:raw.find(']')].split(",")) |