Skip to content
Commits on Source (2)
ntp (1:4.2.8p10+dfsg-3+deb9u2) stretch; urgency=medium
* Cherry-pick patch from upstream to increase stack size.
Thanks to Frederic Endner-Dühr for testing (Closes: #887385)
* Add d/gbp.conf for stretch branch
-- Bernhard Schmidt <berni@debian.org> Thu, 15 Feb 2018 12:45:57 +0100
ntp (1:4.2.8p10+dfsg-3+deb9u1) stretch; urgency=medium
* Build and install /usr/bin/sntp (Closes: #793837)
......
From: Juergen Perlinger <perlinger@ntp.org>
Subject: increase stack size to at least 32kB
Origin: upstream, http://bugs.ntp.org/show_bug.cgi?id=3391
Bug: http://bugs.ntp.org/show_bug.cgi?id=3391
Bug-Debian: https://bugs.debian.org/887385
diff -Nru a/ntpd/ntpd.c b/ntpd/ntpd.c
--- a/ntpd/ntpd.c 2017-03-27 08:33:16.690969527 +0200
+++ b/ntpd/ntpd.c 2017-03-27 08:33:16.690969527 +0200
@@ -313,11 +313,16 @@
#if defined(HAVE_PTHREAD_ATTR_GETSTACKSIZE) && \
defined(HAVE_PTHREAD_ATTR_SETSTACKSIZE) && \
defined(PTHREAD_STACK_MIN)
- rc = pthread_attr_setstacksize(&thr_attr, PTHREAD_STACK_MIN);
- if (0 != rc)
- msyslog(LOG_ERR,
- "my_pthread_warmup: pthread_attr_setstacksize() -> %s",
- strerror(rc));
+ {
+ size_t ssmin = 32*1024; /* 32kB should be minimum */
+ if (ssmin < PTHREAD_STACK_MIN)
+ ssmin = PTHREAD_STACK_MIN;
+ rc = pthread_attr_setstacksize(&thr_attr, ssmin);
+ if (0 != rc)
+ msyslog(LOG_ERR,
+ "my_pthread_warmup: pthread_attr_setstacksize() -> %s",
+ strerror(rc));
+ }
#endif
rc = pthread_create(
&thread, &thr_attr, my_pthread_warmup_worker, NULL);
......@@ -6,3 +6,4 @@ ntpd-linux-caps-runtime.patch
openssl-disable-check.patch
libedit.patch
sntp-sysexits.patch
ntpd-increase-stack-size.patch