diff options
Diffstat (limited to 'rpc/rpcl/rpc-pragmas.h')
-rw-r--r-- | rpc/rpcl/rpc-pragmas.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/rpc/rpcl/rpc-pragmas.h b/rpc/rpcl/rpc-pragmas.h new file mode 100644 index 0000000..91bd501 --- /dev/null +++ b/rpc/rpcl/rpc-pragmas.h @@ -0,0 +1,28 @@ +/* + Copyright (c) 2017 Red Hat, Inc. <http://www.redhat.com> + This file is part of gluster-block. + + This file is licensed to you under your choice of the GNU Lesser + General Public License, version 3 or any later version (LGPLv3 or + later), or the GNU General Public License, version 2 (GPLv2), in all + cases as published by the Free Software Foundation. +*/ + +#ifndef RPC_PRAGMAS_H +#define RPC_PRAGMAS_H + +#if defined(__GNUC__) +#if __GNUC__ >= 4 +#if !defined(__clang__) +#if !defined(__NetBSD__) +#pragma GCC diagnostic ignored "-Wunused-but-set-variable" +#pragma GCC diagnostic ignored "-Wunused-variable" +#endif +#else +#pragma clang diagnostic ignored "-Wunused-variable" +#pragma clang diagnostic ignored "-Wunused-value" +#endif +#endif +#endif + +#endif /* RPC_PRAGMAS_H */ |