diff --git a/test/unit/test_c_api.cpp b/test/unit/test_c_api.cpp index 40da97f9fe..80a8227842 100644 --- a/test/unit/test_c_api.cpp +++ b/test/unit/test_c_api.cpp @@ -48,6 +48,7 @@ #include #if !defined(_WIN32) +#include #include #endif @@ -6114,8 +6115,10 @@ TEST_F(CApi, open_plenty_of_contexts) { struct rlimit open_max_limits; getrlimit(RLIMIT_NOFILE, &open_max_limits); const rlim_t open_file_max = open_max_limits.rlim_cur; + printf("RLIM %ju, sysconf %ju\n", (uintmax_t)open_file_max, (uintmax_t)sysconf(_SC_OPEN_MAX)); for (rlim_t i = 0; i < open_file_max - 50; i++) { FILE *f = fopen("/dev/null", "rb"); + printf("%ju, ", (uintmax_t)i); ASSERT_TRUE(f != nullptr); dummyFilePointers.push_back(f); } diff --git a/travis/linux_generic/install.sh b/travis/linux_generic/install.sh index f2db7e4bbe..6c372b41b6 100755 --- a/travis/linux_generic/install.sh +++ b/travis/linux_generic/install.sh @@ -7,3 +7,6 @@ export PROJ_DB_CACHE_DIR="$HOME/.ccache" # -fno-use-cxa-atexit is needed to build with -coverage CC="ccache $CC" CXX="ccache $CXX" CFLAGS="-Werror" CXXFLAGS="-Werror" ./travis/install.sh + +printf "ULIMITS:\n" +ulimit -a