mirror of https://github.com/dynup/kpatch
17 lines
525 B
Diff
17 lines
525 B
Diff
|
ensure timekeeping_forward_now.constprop.8 and
|
||
|
timekeeping_forward_now.constprop.9 are correlated.
|
||
|
|
||
|
diff -Nupr src.orig/kernel/time/timekeeping.c src/kernel/time/timekeeping.c
|
||
|
--- src.orig/kernel/time/timekeeping.c 2016-12-15 19:56:00.136000000 +0000
|
||
|
+++ src/kernel/time/timekeeping.c 2016-12-15 19:56:30.496000000 +0000
|
||
|
@@ -1148,6 +1148,9 @@ void do_gettimeofday(struct timeval *tv)
|
||
|
{
|
||
|
struct timespec64 now;
|
||
|
|
||
|
+ if (!tv)
|
||
|
+ return;
|
||
|
+
|
||
|
getnstimeofday64(&now);
|
||
|
tv->tv_sec = now.tv_sec;
|
||
|
tv->tv_usec = now.tv_nsec/1000;
|