htpdate: use adjtimex instead of the obsolete ntp_adjtime
git-svn-id: svn://svn.openwrt.org/openwrt/packages@16189 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
75632e0ad5
commit
2503e046ef
20
net/htpdate/patches/100-adjtimex.patch
Normal file
20
net/htpdate/patches/100-adjtimex.patch
Normal file
@ -0,0 +1,20 @@
|
||||
--- a/htpdate.c
|
||||
+++ b/htpdate.c
|
||||
@@ -349,7 +349,7 @@
|
||||
|
||||
/* Read current kernel frequency */
|
||||
tmx.modes = 0;
|
||||
- ntp_adjtime(&tmx);
|
||||
+ adjtimex(&tmx);
|
||||
|
||||
/* Calculate new frequency */
|
||||
freq = (long)(65536e6 * drift);
|
||||
@@ -364,7 +364,7 @@
|
||||
|
||||
/* Become root */
|
||||
seteuid(0);
|
||||
- return( ntp_adjtime(&tmx) );
|
||||
+ return( adjtimex(&tmx) );
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user