aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/erl_map.c
diff options
context:
space:
mode:
authorJohn Högberg <[email protected]>2018-03-20 13:28:26 +0100
committerJohn Högberg <[email protected]>2018-03-23 08:18:20 +0100
commit187564ffccee4a3b5727bdab3df2458f3b5ced72 (patch)
tree414b9224d03ced77299a3296a22e664bca324efd /erts/emulator/beam/erl_map.c
parentb302412387b094bb827ea8ae5f8f3e28178c2f8b (diff)
downloadotp-187564ffccee4a3b5727bdab3df2458f3b5ced72.tar.gz
otp-187564ffccee4a3b5727bdab3df2458f3b5ced72.tar.bz2
otp-187564ffccee4a3b5727bdab3df2458f3b5ced72.zip
Add enif_make_map_from_arrays
Diffstat (limited to 'erts/emulator/beam/erl_map.c')
-rw-r--r--erts/emulator/beam/erl_map.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/erts/emulator/beam/erl_map.c b/erts/emulator/beam/erl_map.c
index 8047a9567f..4ec6960997 100644
--- a/erts/emulator/beam/erl_map.c
+++ b/erts/emulator/beam/erl_map.c
@@ -490,7 +490,9 @@ Eterm erts_map_from_ks_and_vs(ErtsHeapFactory *factory, Eterm *ks0, Eterm *vs0,
sys_memcpy(ks, ks0, n * sizeof(Eterm));
sys_memcpy(vs, vs0, n * sizeof(Eterm));
- erts_validate_and_sort_flatmap(mp);
+ if (!erts_validate_and_sort_flatmap(mp)) {
+ return THE_NON_VALUE;
+ }
return make_flatmap(mp);
} else {