aboutsummaryrefslogtreecommitdiff
path: root/zenstore-test/zenstore-test.cpp
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2022-04-12 19:20:51 +0200
committerDan Engelbrecht <[email protected]>2022-04-12 19:20:51 +0200
commitf4ba5e54262ed2d67fdaee803a212bdafa1cf2aa (patch)
treeba5c72255cfd8ce8317c2ec53403c2f863f7f404 /zenstore-test/zenstore-test.cpp
parentset file limit on zenserver test (diff)
downloadzen-f4ba5e54262ed2d67fdaee803a212bdafa1cf2aa.tar.xz
zen-f4ba5e54262ed2d67fdaee803a212bdafa1cf2aa.zip
cleanup
Diffstat (limited to 'zenstore-test/zenstore-test.cpp')
-rw-r--r--zenstore-test/zenstore-test.cpp24
1 files changed, 1 insertions, 23 deletions
diff --git a/zenstore-test/zenstore-test.cpp b/zenstore-test/zenstore-test.cpp
index 6ebd60e95..704470f8e 100644
--- a/zenstore-test/zenstore-test.cpp
+++ b/zenstore-test/zenstore-test.cpp
@@ -23,29 +23,7 @@ main([[maybe_unused]] int argc, [[maybe_unused]] char* argv[])
zen::zenstore_forcelinktests();
zen::logging::InitializeLogging();
-
-#if ZEN_PLATFORM_LINUX || ZEN_PLATFORM_MAC
- struct rlimit Limit;
- int Error = getrlimit(RLIMIT_NOFILE, &Limit);
- if (Error)
- {
- ZEN_WARN("failed getting rlimit RLIMIT_NOFILE, reason '{}'", zen::MakeErrorCode(Error).message());
- }
- else
- {
- struct rlimit NewLimit = Limit;
-// NewLimit.rlim_cur = 10240;
-// NewLimit.rlim_max = 10240;
- NewLimit.rlim_cur = NewLimit.rlim_max;
- ZEN_INFO("changing RLIMIT_NOFILE from rlim_cur = {}, rlim_max {} to rlim_cur = {}, rlim_max {}", Limit.rlim_cur, Limit.rlim_max, NewLimit.rlim_cur, NewLimit.rlim_max);
-
- Error = setrlimit(RLIMIT_NOFILE, &NewLimit);
- if (Error != 0)
- {
- ZEN_WARN("failed to set RLIMIT_NOFILE limits from rlim_cur = {}, rlim_max {} to rlim_cur = {}, rlim_max {}, reason '{}'", Limit.rlim_cur, Limit.rlim_max, NewLimit.rlim_cur, NewLimit.rlim_max, zen::MakeErrorCode(Error).message());
- }
- }
-#endif
+ zen::InitializeOpenFileCount();
return doctest::Context(argc, argv).run();
#else