From 4216df5bedb132ff0c2cebdcea571f0a98c69a89 Mon Sep 17 00:00:00 2001 From: Tor Egge Date: Tue, 11 Sep 2018 10:37:19 +0000 Subject: The first memory mapped region can be a long distance from the second one if there is a hole in the memory mapping. Add a dummy mapping to plug this hole. --- vespalib/src/tests/alloc/alloc_test.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'vespalib') diff --git a/vespalib/src/tests/alloc/alloc_test.cpp b/vespalib/src/tests/alloc/alloc_test.cpp index 0e52d06a2d5..dd4adfc2fa1 100644 --- a/vespalib/src/tests/alloc/alloc_test.cpp +++ b/vespalib/src/tests/alloc/alloc_test.cpp @@ -179,6 +179,7 @@ TEST("auto alloced mmap alloc can not be extended if no room") { } TEST("mmap alloc can be extended if room") { + Alloc dummy = Alloc::allocMMap(100); Alloc reserved = Alloc::allocMMap(100); Alloc buf = Alloc::allocMMap(100); @@ -187,6 +188,7 @@ TEST("mmap alloc can be extended if room") { } TEST("mmap alloc can not be extended if no room") { + Alloc dummy = Alloc::allocMMap(100); Alloc reserved = Alloc::allocMMap(100); Alloc buf = Alloc::allocMMap(100); -- cgit v1.2.3