From d642b94209ac7e676d988e08f8e2efad0827758b Mon Sep 17 00:00:00 2001 From: Eugene Grosbein Date: Mon, 19 Nov 2018 07:27:50 +0000 Subject: [PATCH] Unbreak ng_source(4) for 64-bit platforms including amd64. --- sys/netgraph/ng_source.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/netgraph/ng_source.c b/sys/netgraph/ng_source.c index ea341b6ce7c1..a82982db943f 100644 --- a/sys/netgraph/ng_source.c +++ b/sys/netgraph/ng_source.c @@ -125,8 +125,13 @@ static int ng_source_dup_mod(sc_p, struct mbuf *, /* Parse type for timeval */ static const struct ng_parse_struct_field ng_source_timeval_type_fields[] = { +#ifdef __LP64__ + { "tv_sec", &ng_parse_int64_type }, + { "tv_usec", &ng_parse_int64_type }, +#else { "tv_sec", &ng_parse_int32_type }, { "tv_usec", &ng_parse_int32_type }, +#endif { NULL } }; const struct ng_parse_type ng_source_timeval_type = {