2021-07-19 04:39:47 +02:00
|
|
|
diff -Nur openntpd-6.8p1.orig/src/ntpd.c openntpd-6.8p1/src/ntpd.c
|
|
|
|
--- openntpd-6.8p1.orig/src/ntpd.c 2020-12-07 02:20:35.000000000 -0600
|
|
|
|
+++ openntpd-6.8p1/src/ntpd.c 2021-07-18 21:33:55.169706930 -0500
|
|
|
|
@@ -113,9 +113,8 @@
|
2015-01-09 01:10:40 +01:00
|
|
|
{
|
|
|
|
extern char *__progname;
|
|
|
|
|
|
|
|
- if (strcmp(__progname, "ntpctl") == 0)
|
2015-03-27 13:28:57 +01:00
|
|
|
- fprintf(stderr,
|
|
|
|
- "usage: ntpctl -s all | peers | Sensors | status\n");
|
2015-01-09 01:10:40 +01:00
|
|
|
+ if (strcmp(__progname, "openntpctl") == 0)
|
2015-03-27 13:28:57 +01:00
|
|
|
+ fprintf(stderr, "usage: %s -s all | peers | Sensors | status\n", __progname);
|
2015-01-09 01:10:40 +01:00
|
|
|
else
|
2021-07-19 04:39:47 +02:00
|
|
|
fprintf(stderr, "usage: %s [-dnv] [-f file] [-p file]\n",
|
2015-01-09 01:10:40 +01:00
|
|
|
__progname);
|
2021-07-19 04:39:47 +02:00
|
|
|
@@ -171,7 +170,7 @@
|
|
|
|
|
|
|
|
__progname = get_progname(argv[0]);
|
2015-01-09 01:10:40 +01:00
|
|
|
|
|
|
|
- if (strcmp(__progname, "ntpctl") == 0) {
|
|
|
|
+ if (strcmp(__progname, "openntpctl") == 0) {
|
2015-03-27 13:28:57 +01:00
|
|
|
ctl_main(argc, argv);
|
2015-01-09 01:10:40 +01:00
|
|
|
/* NOTREACHED */
|
|
|
|
}
|
2021-07-19 04:39:47 +02:00
|
|
|
@@ -736,7 +735,7 @@
|
2015-01-20 15:50:45 +01:00
|
|
|
/* NOTREACHED */
|
2015-01-09 01:10:40 +01:00
|
|
|
|
|
|
|
if ((fd = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
|
|
|
|
- err(1, "ntpctl: socket");
|
|
|
|
+ err(1, "openntpctl: socket");
|
|
|
|
|
2021-07-19 04:39:47 +02:00
|
|
|
memset(&sa, 0, sizeof(sa));
|
2015-01-09 01:10:40 +01:00
|
|
|
sa.sun_family = AF_UNIX;
|
2021-07-19 04:39:47 +02:00
|
|
|
@@ -784,7 +783,7 @@
|
|
|
|
if ((n = imsg_read(ibuf_ctl)) == -1 && errno != EAGAIN)
|
2015-01-09 01:10:40 +01:00
|
|
|
err(1, "ibuf_ctl: imsg_read error");
|
|
|
|
if (n == 0)
|
|
|
|
- errx(1, "ntpctl: pipe closed");
|
|
|
|
+ errx(1, "openntpctl: pipe closed");
|
|
|
|
|
|
|
|
while (!done) {
|
|
|
|
if ((n = imsg_get(ibuf_ctl, &imsg)) == -1)
|