From 91c83d9675ad2e2d2f4b30a502726dfe22792cb7 Mon Sep 17 00:00:00 2001 From: Sami Kerola Date: Sat, 28 Sep 2019 20:51:45 +0100 Subject: [PATCH] various: add header guards [lgtm scan] Reference: https://lgtm.com/projects/g/iputils/iputils/?mode=list Signed-off-by: Sami Kerola --- ninfod/ninfod.h | 3 +++ ping/ping.h | 5 +++++ tftpd/tftp.h | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/ninfod/ninfod.h b/ninfod/ninfod.h index d4e7d679..94c895ec 100644 --- a/ninfod/ninfod.h +++ b/ninfod/ninfod.h @@ -31,6 +31,8 @@ * Author: * YOSHIFUJI Hideaki */ +#ifndef IPUTILS_NINFOD_H +#define IPUTILS_NINFOD_H /* definitions */ #define NINFOD "ninfod" @@ -118,3 +120,4 @@ int pr_nodeinfo_ipv4addr(CHECKANDFILL_ARGS); void init_nodeinfo_nodename(INIT_ARGS); int pr_nodeinfo_nodename(CHECKANDFILL_ARGS); +#endif /* IPUTILS_NINFOD_H */ diff --git a/ping/ping.h b/ping/ping.h index 20ac3e8c..a90c4665 100644 --- a/ping/ping.h +++ b/ping/ping.h @@ -1,3 +1,6 @@ +#ifndef IPUTILS_PING_H +#define IPUTILS_PING_H + /* Includes */ #include #include @@ -409,3 +412,5 @@ struct ni_hdr { #define ni_cksum ni_u.icmp6_cksum #define ni_qtype ni_u.icmp6_data16[0] #define ni_flags ni_u.icmp6_data16[1] + +#endif /* IPUTILS_PING_H */ diff --git a/tftpd/tftp.h b/tftpd/tftp.h index c8393cc8..e7dfba13 100644 --- a/tftpd/tftp.h +++ b/tftpd/tftp.h @@ -1,3 +1,5 @@ +#ifndef IPUTILS_TFTPD_H +#define IPUTILS_TFTPD_H /* * Copyright (c) 1983, 1993 * The Regents of the University of California. All rights reserved. @@ -38,3 +40,5 @@ extern int write_behind(FILE *file, int convert); extern int synchnet(int f); extern struct tftphdr *w_init(void); extern struct tftphdr *r_init(void); + +#endif /* IPUTILS_TFTPD_H */