summaryrefslogtreecommitdiff
path: root/erts/emulator/beam/erl_map.c
diff options
context:
space:
mode:
authorSverker Eriksson <sverker@erlang.org>2019-02-06 19:08:25 +0100
committerSverker Eriksson <sverker@erlang.org>2019-02-06 19:08:25 +0100
commite2ca71b6e7172b320b5b171359d53a161383fb19 (patch)
tree6e17f4302d70ea4b27bab1fc5cd0940e11493e1d /erts/emulator/beam/erl_map.c
parente6059f94571a6c968c15b9de6b7d63ebd64f9acf (diff)
downloaderlang-e2ca71b6e7172b320b5b171359d53a161383fb19.tar.gz
erts: Fix bug in erts_map_from_ks_and_vs
This sleeping bug was introduced in OTP 19.1 but not possible not provoke until OTP 21.0 when enif_make_map_from_arrays was introduced.
Diffstat (limited to 'erts/emulator/beam/erl_map.c')
-rw-r--r--erts/emulator/beam/erl_map.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/erts/emulator/beam/erl_map.c b/erts/emulator/beam/erl_map.c
index 979a0040b0..b48017d338 100644
--- a/erts/emulator/beam/erl_map.c
+++ b/erts/emulator/beam/erl_map.c
@@ -499,7 +499,7 @@ Eterm erts_hashmap_from_array(ErtsHeapFactory* factory, Eterm *leafs, Uint n,
Eterm erts_map_from_ks_and_vs(ErtsHeapFactory *factory, Eterm *ks0, Eterm *vs0, Uint n)
{
- if (n < MAP_SMALL_MAP_LIMIT) {
+ if (n <= MAP_SMALL_MAP_LIMIT) {
Eterm *ks, *vs, *hp;
flatmap_t *mp;
Eterm keys;