summaryrefslogtreecommitdiff
path: root/net/ntp-devel/files/patch-ntpd_ntp.c
blob: f25751470f47bf2c4670c7fb3afd5efe3a178781 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
--- ntpd/ntpd.c.orig	2019-06-07 01:59:15.000000000 -0700
+++ ntpd/ntpd.c	2019-09-20 12:13:28.810552000 -0700
@@ -999,7 +999,7 @@
 # if defined(HAVE_MLOCKALL)
 #  ifdef HAVE_SETRLIMIT
 	ntp_rlimit(RLIMIT_STACK, DFLT_RLIMIT_STACK * 4096, 4096, "4k");
-#   ifdef RLIMIT_MEMLOCK
+#   if defined(RLIMIT_MEMLOCK) && defined(DFLT_RLIMIT_MEMLOCK) && DFLT_RLIMIT_MEMLOCK != -1
 	/*
 	 * The default RLIMIT_MEMLOCK is very low on Linux systems.
 	 * Unless we increase this limit malloc calls are likely to