Commit a26a5974 authored by Tatsuhiro Tsujikawa's avatar Tatsuhiro Tsujikawa

nghttpx: Cast configuration value to rlim_t to avoid compile error on 32bit

parent 20a689ef
......@@ -1911,8 +1911,8 @@ int main(int argc, char **argv) {
}
if (get_config()->rlimit_nofile) {
struct rlimit lim = {get_config()->rlimit_nofile,
get_config()->rlimit_nofile};
struct rlimit lim = {static_cast<rlim_t>(get_config()->rlimit_nofile),
static_cast<rlim_t>(get_config()->rlimit_nofile)};
if (setrlimit(RLIMIT_NOFILE, &lim) != 0) {
auto error = errno;
LOG(WARN) << "Setting rlimit-nofile failed: " << strerror(error);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment