From bae22a45d837e76e805f0f411b2d71748e76625e Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Tue, 1 Jun 2021 17:48:26 +0200 Subject: [PATCH] lgtm: suppress lgtm[cpp/duplicate-include-guard] warning in ethtool header lgtm.com doesn't like this: Query pack:com.lgtm/cpp-queries Query ID:cpp/duplicate-include-guard Using the same include guard macro in more than one header file may cause unexpected behavior from the compiler. both for src/libnm-base/nm-ethtool-utils-base.h and src/libnm-client-public/nm-ethtool-utils.h. But this is intentional, because these two files are supposed to be identical (but compiled twice, under different context). Suppress the warning. --- src/libnm-base/nm-ethtool-utils-base.h | 2 +- src/libnm-client-public/nm-ethtool-utils.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libnm-base/nm-ethtool-utils-base.h b/src/libnm-base/nm-ethtool-utils-base.h index fa9c30715..3656ed3f9 100644 --- a/src/libnm-base/nm-ethtool-utils-base.h +++ b/src/libnm-base/nm-ethtool-utils-base.h @@ -3,7 +3,7 @@ * Copyright (C) 2018 Red Hat, Inc. */ -#ifndef __NM_ETHTOOL_UTILS_H__ +#ifndef __NM_ETHTOOL_UTILS_H__ /* lgtm[cpp/duplicate-include-guard] */ #define __NM_ETHTOOL_UTILS_H__ G_BEGIN_DECLS diff --git a/src/libnm-client-public/nm-ethtool-utils.h b/src/libnm-client-public/nm-ethtool-utils.h index fa9c30715..3656ed3f9 100644 --- a/src/libnm-client-public/nm-ethtool-utils.h +++ b/src/libnm-client-public/nm-ethtool-utils.h @@ -3,7 +3,7 @@ * Copyright (C) 2018 Red Hat, Inc. */ -#ifndef __NM_ETHTOOL_UTILS_H__ +#ifndef __NM_ETHTOOL_UTILS_H__ /* lgtm[cpp/duplicate-include-guard] */ #define __NM_ETHTOOL_UTILS_H__ G_BEGIN_DECLS