diff options
author | Björn-Egil Dahlberg <[email protected]> | 2015-05-07 11:58:23 +0200 |
---|---|---|
committer | Björn-Egil Dahlberg <[email protected]> | 2015-05-07 11:58:23 +0200 |
commit | beb883ed443dfeb41f239363f36c511dd43c7eec (patch) | |
tree | 71d28be0233c1b42ee461ed14971fe1366456e2c /erts/emulator/beam | |
parent | 36fe05d30ecb1bc7b8d4665bff38caf61c9ae0f8 (diff) | |
download | otp-beb883ed443dfeb41f239363f36c511dd43c7eec.tar.gz otp-beb883ed443dfeb41f239363f36c511dd43c7eec.tar.bz2 otp-beb883ed443dfeb41f239363f36c511dd43c7eec.zip |
erts: Fix ETS db_has_variable check for large Maps
Diffstat (limited to 'erts/emulator/beam')
-rw-r--r-- | erts/emulator/beam/erl_db_util.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/erts/emulator/beam/erl_db_util.c b/erts/emulator/beam/erl_db_util.c index be988f0621..a75267ca97 100644 --- a/erts/emulator/beam/erl_db_util.c +++ b/erts/emulator/beam/erl_db_util.c @@ -3411,6 +3411,11 @@ int db_has_variable(Eterm node) { while (size--) { ESTACK_PUSH(s, *(values++)); } + } else if (is_map(node)) { /* other map-nodes or map-heads */ + Eterm *ptr = hashmap_val(node); + int i = hashmap_bitcount(MAP_HEADER_VAL(*ptr)); + ptr += MAP_HEADER_ARITY(*ptr); + while(i--) { ESTACK_PUSH(s, *++ptr); } } break; case TAG_PRIMARY_IMMED1: |