From 7b7ed885aff2eede24d641c3b042ebcf7517a5c5 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Mon, 25 Mar 2019 09:17:23 -0700 Subject: net/core: Allow the compiler to verify declaration and definition consistency Instead of declaring a function in a .c file, declare it in a header file and include that header file from the source files that define and that use the function. That allows the compiler to verify consistency of declaration and definition. See also commit 52267790ef52 ("sock: add MSG_ZEROCOPY") # v4.14. Cc: Willem de Bruijn Signed-off-by: Bart Van Assche Signed-off-by: David S. Miller --- net/core/datagram.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'net/core/datagram.c') diff --git a/net/core/datagram.c b/net/core/datagram.c index ed8accb17418..0dafec5cada0 100644 --- a/net/core/datagram.c +++ b/net/core/datagram.c @@ -61,6 +61,8 @@ #include #include +#include "datagram.h" + /* * Is a socket 'connection oriented' ? */ -- cgit v1.2.3