diff options
author | Christoph Junghans <ottxor@gentoo.org> | 2016-02-01 11:04:48 -0700 |
---|---|---|
committer | Christoph Junghans <ottxor@gentoo.org> | 2016-02-01 11:04:48 -0700 |
commit | f55c32a55520092034056e81c583585c9601acd2 (patch) | |
tree | 6f699aeea8b5c922f47545555d9cf7f01e396307 /net-misc/openntpd/files | |
parent | app-text/tesseract: Remove old (diff) | |
download | gentoo-f55c32a55520092034056e81c583585c9601acd2.tar.gz gentoo-f55c32a55520092034056e81c583585c9601acd2.tar.bz2 gentoo-f55c32a55520092034056e81c583585c9601acd2.zip |
net-misc/openntpd: remove old
Package-Manager: portage-2.2.26
Diffstat (limited to 'net-misc/openntpd/files')
3 files changed, 0 insertions, 244 deletions
diff --git a/net-misc/openntpd/files/openntpd-20080406-dns-timeout.patch b/net-misc/openntpd/files/openntpd-20080406-dns-timeout.patch deleted file mode 100644 index 6026037331a7..000000000000 --- a/net-misc/openntpd/files/openntpd-20080406-dns-timeout.patch +++ /dev/null @@ -1,46 +0,0 @@ -fix dns lookups timeout -https://bugs.gentoo.org/show_bug.cgi?id=493358 - -diff -u openntpd-20080406p-orig/ntpd.c openntpd-20080406p/ntpd.c ---- openntpd-20080406p-orig/ntpd.c 2013-12-04 20:12:02.562857933 -0800 -+++ openntpd-20080406p/ntpd.c 2013-12-04 20:22:55.617577783 -0800 -@@ -34,6 +34,7 @@ - #include <stdio.h> - #include <stdlib.h> - #include <string.h> -+#include <time.h> - #include <unistd.h> - - #include "ntpd.h" -@@ -95,6 +96,7 @@ - int ch, nfds, timeout = INFTIM; - int pipe_chld[2]; - extern char *__progname; -+ time_t start_time; - - __progname = _compat_get_progname(argv[0]); - -@@ -197,6 +199,8 @@ - fatal(NULL); - imsg_init(ibuf, pipe_chld[0]); - -+ start_time = getmonotime(); -+ - while (quit == 0) { - pfd[PFD_PIPE].fd = ibuf->fd; - pfd[PFD_PIPE].events = POLLIN; -@@ -209,11 +213,12 @@ - quit = 1; - } - -- if (nfds == 0 && lconf.settime) { -+ if (lconf.settime && -+ (nfds == 0 || getmonotime() > start_time+SETTIME_TIMEOUT)) { - lconf.settime = 0; - timeout = INFTIM; - log_init(lconf.debug); -- log_debug("no reply received in time, skipping initial " -+ log_warnx("no reply received in time, skipping initial " - "time setting"); - if (!lconf.debug) { - if (daemon(1, 0)) diff --git a/net-misc/openntpd/files/openntpd-20080406-pidfile.patch b/net-misc/openntpd/files/openntpd-20080406-pidfile.patch deleted file mode 100644 index d2ee38504c3e..000000000000 --- a/net-misc/openntpd/files/openntpd-20080406-pidfile.patch +++ /dev/null @@ -1,141 +0,0 @@ -adding a -p option to openntpd to create a pidfile - -https://bugs.gentoo.org/show_bug.cgi?id=493082 - -diff -u -r openntpd-20080406p.orig/ntpd.8 openntpd-20080406p/ntpd.8 ---- openntpd-20080406p.orig/ntpd.8 2013-12-01 12:49:49.773116316 -0800 -+++ openntpd-20080406p/ntpd.8 2013-12-01 13:27:39.417324497 -0800 -@@ -25,6 +25,7 @@ - .Bk -words - .Op Fl dnSsv - .Op Fl f Ar file -+.Op Fl p Ar file - .Ek - .Sh DESCRIPTION - The -@@ -63,13 +64,16 @@ - .Xr ntpd.conf 5 . - .Pp - The options are as follows: --.Bl -tag -width "-f fileXXX" -+.Bl -tag -width "-p fileXXX" - .It Fl d - Do not daemonize. - If this option is specified, - .Nm - will run in the foreground and log to - .Em stderr . -+.It Fl p Ar file -+Write pid to -+.Ar file - .It Fl f Ar file - Use - .Ar file -diff -u -r openntpd-20080406p.orig/ntpd.c openntpd-20080406p/ntpd.c ---- openntpd-20080406p.orig/ntpd.c 2013-12-01 12:49:49.774116176 -0800 -+++ openntpd-20080406p/ntpd.c 2013-12-01 13:31:43.964616270 -0800 -@@ -78,7 +78,7 @@ - { - extern char *__progname; - -- fprintf(stderr, "usage: %s [-dnSsv] [-f file]\n", __progname); -+ fprintf(stderr, "usage: %s [-dnSsv] [-f file] [-p file]\n", __progname); - exit(1); - } - -@@ -105,7 +105,7 @@ - log_init(1); /* log to stderr until daemonized */ - res_init(); /* XXX */ - -- while ((ch = getopt(argc, argv, "df:nsSv")) != -1) { -+ while ((ch = getopt(argc, argv, "df:np:sSv")) != -1) { - switch (ch) { - case 'd': - lconf.debug = 1; -@@ -116,6 +116,9 @@ - case 'n': - lconf.noaction = 1; - break; -+ case 'p': -+ lconf.pid_file = optarg; -+ break; - case 's': - lconf.settime = 1; - break; -@@ -157,9 +160,17 @@ - reset_adjtime(); - if (!lconf.settime) { - log_init(lconf.debug); -- if (!lconf.debug) -+ if (!lconf.debug) { - if (daemon(1, 0)) - fatal("daemon"); -+ else if (lconf.pid_file != NULL) { -+ FILE *f = fopen(lconf.pid_file, "w"); -+ if (f == NULL) -+ fatal("couldn't open pid file"); -+ fprintf(f, "%ld\n", (long) getpid()); -+ fclose(f); -+ } -+ } - } else - timeout = SETTIME_TIMEOUT * 1000; - -@@ -201,9 +212,17 @@ - log_init(lconf.debug); - log_debug("no reply received in time, skipping initial " - "time setting"); -- if (!lconf.debug) -+ if (!lconf.debug) { - if (daemon(1, 0)) - fatal("daemon"); -+ else if (lconf.pid_file != NULL) { -+ FILE *f = fopen(lconf.pid_file, "w"); -+ if (f == NULL) -+ fatal("couldn't open pid file"); -+ fprintf(f, "%ld\n", (long) getpid()); -+ fclose(f); -+ } -+ } - } - - if (nfds > 0 && (pfd[PFD_PIPE].revents & POLLOUT)) -@@ -242,6 +261,8 @@ - msgbuf_clear(&ibuf->w); - free(ibuf); - log_info("Terminating"); -+ if (lconf.pid_file != NULL) -+ unlink(lconf.pid_file); - return (0); - } - -@@ -316,9 +337,17 @@ - memcpy(&d, imsg.data, sizeof(d)); - ntpd_settime(d); - /* daemonize now */ -- if (!lconf->debug) -+ if (!lconf->debug) { - if (daemon(1, 0)) - fatal("daemon"); -+ else if (lconf->pid_file != NULL) { -+ FILE *f = fopen(lconf->pid_file, "w"); -+ if (f == NULL) -+ fatal("couldn't open pid file"); -+ fprintf(f, "%ld\n", (long) getpid()); -+ fclose(f); -+ } -+ } - lconf->settime = 0; - break; - case IMSG_HOST_DNS: -diff -u -r openntpd-20080406p.orig/ntpd.h openntpd-20080406p/ntpd.h ---- openntpd-20080406p.orig/ntpd.h 2013-12-01 12:49:49.773116316 -0800 -+++ openntpd-20080406p/ntpd.h 2013-12-01 12:54:02.023313872 -0800 -@@ -178,6 +178,7 @@ - u_int8_t debug; - u_int32_t scale; - u_int8_t noaction; -+ char *pid_file; - }; - - struct buf { diff --git a/net-misc/openntpd/files/openntpd-20080406-signal.patch b/net-misc/openntpd/files/openntpd-20080406-signal.patch deleted file mode 100644 index 695beecb36c9..000000000000 --- a/net-misc/openntpd/files/openntpd-20080406-signal.patch +++ /dev/null @@ -1,57 +0,0 @@ -allow SIGUSR1 as stand-in for SIGINFO (on e.g linux) -https://bugs.gentoo.org/show_bug.cgi?id=493084 - -diff -u openntpd-20080406p-orig/ntp.c openntpd-20080406p/ntp.c ---- openntpd-20080406p-orig/ntp.c 2013-12-04 15:11:04.417274938 -0800 -+++ openntpd-20080406p/ntp.c 2013-12-04 15:12:21.066006404 -0800 -@@ -67,9 +67,11 @@ - break; - #ifdef HAVE_SIGINFO - case SIGINFO: -- ntp_report = 1; -- break; -+#else -+ case SIGUSR1: - #endif -+ ntp_report = 1; -+ break; - } - } - -@@ -158,6 +160,8 @@ - signal(SIGINT, ntp_sighdlr); - #ifdef USE_SIGINFO - signal(SIGINFO, ntp_sighdlr); -+#else -+ signal(SIGUSR1, ntp_sighdlr); - #endif - signal(SIGPIPE, SIG_IGN); - signal(SIGHUP, SIG_IGN); -diff -u openntpd-20080406p-orig/ntpd.8 openntpd-20080406p/ntpd.8 ---- openntpd-20080406p-orig/ntpd.8 2013-12-04 15:11:04.416274915 -0800 -+++ openntpd-20080406p/ntpd.8 2013-12-04 15:12:21.066006404 -0800 -@@ -104,7 +104,11 @@ - .Nm - receives a - .Dv SIGINFO --signal, it will write its peer and sensor status to syslog. -+signal (or a -+.Dv SIGUSR1 -+signal on systems without -+.Dv SIGINFO -+), it will write its peer and sensor status to syslog. - .Sh FILES - .Bl -tag -width "/var/lib/openntpd/ntpd.driftXXX" -compact - .It Pa /etc/ntpd.conf -diff -u openntpd-20080406p-orig/ntpd.c openntpd-20080406p/ntpd.c ---- openntpd-20080406p-orig/ntpd.c 2013-12-04 15:11:04.416274915 -0800 -+++ openntpd-20080406p/ntpd.c 2013-12-04 15:14:21.586728922 -0800 -@@ -187,6 +187,9 @@ - signal(SIGTERM, sighdlr); - signal(SIGINT, sighdlr); - signal(SIGHUP, sighdlr); -+ #ifndef HAVE_SIGINFO -+ signal(SIGUSR1, SIG_IGN); -+ #endif - - close(pipe_chld[1]); |