]> git.ozlabs.org Git - ppp.git/commitdiff
pppd: Include time.h header before using time_t
authorKurt Van Dijck <dev.kurt@vandijck-laurijssen.be>
Fri, 4 Oct 2019 17:40:46 +0000 (19:40 +0200)
committerPaul Mackerras <paulus@ozlabs.org>
Sun, 1 Dec 2019 05:15:00 +0000 (16:15 +1100)
Since include/net/ppp_defs.h is used in both kernelspace and userland
it is hard to include <time.h> there.
This commit fixes the problems in userspace code individually and leaves
ppp_defs.h as-is.

Signed-off-by: Kurt Van Dijck <dev.kurt@vandijck-laurijssen.be>
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
pppd/plugins/rp-pppoe/pppoe-discovery.c
pppd/sha1.c

index 8b2e946f4d711d516e6f43fc73dbd45405c8b7a9..f19c6d8b58318203430401ab641236be82d24c4e 100644 (file)
@@ -15,6 +15,7 @@
 #include <unistd.h>
 #include <errno.h>
 #include <string.h>
+#include <time.h>
 
 #include "pppoe.h"
 
index f4f975cf516f6c9b58516f08a71152bdef62beca..4e51cee506c237ce2385ad3ed94003e31c9f1914 100644 (file)
@@ -17,6 +17,7 @@
 /* #define SHA1HANDSOFF * Copies data before messing with it. */
 
 #include <string.h>
+#include <time.h>
 #include <netinet/in.h>        /* htonl() */
 #include <net/ppp_defs.h>
 #include "sha1.h"