flm01/mote/v1/openwrt/package/ntpclient/patches/100-daemon.patch

25 lines
670 B
Diff
Raw Permalink Normal View History

Index: ntpclient-2007/ntpclient.c
===================================================================
--- ntpclient-2007.orig/ntpclient.c 2008-08-12 03:11:34.000000000 +0200
+++ ntpclient-2007/ntpclient.c 2008-08-12 03:11:36.000000000 +0200
@@ -614,7 +614,7 @@
ntpc.cross_check=1;
for (;;) {
- c = getopt( argc, argv, "c:" DEBUG_OPTION "f:g:h:i:lp:q:" REPLAY_OPTION "st");
+ c = getopt( argc, argv, "c:" DEBUG_OPTION "f:g:h:i:lp:q:" REPLAY_OPTION "stD");
if (c == EOF) break;
switch (c) {
case 'c':
@@ -663,6 +663,10 @@
(ntpc.cross_check)=0;
break;
+ case 'D':
+ daemon();
+ break;
+
default:
usage(argv[0]);
exit(1);