From 680f25f8edb8b95c8030c4983fb0afd5408c565e Mon Sep 17 00:00:00 2001 From: Ruben Kerkhof Date: Sun, 28 Dec 2014 16:50:08 +0100 Subject: [PATCH] Add missing include guards --- modules/bindbackend/bindbackend2.hh | 5 +++++ modules/geobackend/geobackend.hh | 5 ++++- modules/geobackend/ippreftree.hh | 4 ++++ modules/geoipbackend/geoipbackend.hh | 5 +++++ modules/gmysqlbackend/gmysqlbackend.hh | 5 +++++ modules/goraclebackend/goraclebackend.hh | 5 +++++ modules/gpgsqlbackend/gpgsqlbackend.hh | 5 +++++ modules/lmdbbackend/lmdbbackend.hh | 4 ++++ modules/oraclebackend/oraclebackend.hh | 5 +++-- pdns/backends/gsql/gsqlbackend.hh | 5 +++++ pdns/comment.hh | 6 +++++- pdns/pkcs11signers.hh | 4 ++++ pdns/resolver.hh | 3 +++ pdns/ws-api.hh | 5 +++++ pdns/ws-recursor.hh | 5 +++++ 15 files changed, 67 insertions(+), 4 deletions(-) diff --git a/modules/bindbackend/bindbackend2.hh b/modules/bindbackend/bindbackend2.hh index 9ced301b99..0eb31104fe 100644 --- a/modules/bindbackend/bindbackend2.hh +++ b/modules/bindbackend/bindbackend2.hh @@ -19,6 +19,9 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PDNS_BINDBACKEND_HH +#define PDNS_BINDBACKEND_HH + #include #include #include @@ -302,3 +305,5 @@ private: void loadConfig(string *status=0); static void nukeZoneRecords(BB2DomainInfo *bbd); }; + +#endif /* PDNS_BINDBACKEND_HH */ diff --git a/modules/geobackend/geobackend.hh b/modules/geobackend/geobackend.hh index 1ae5874384..b135f27456 100644 --- a/modules/geobackend/geobackend.hh +++ b/modules/geobackend/geobackend.hh @@ -4,7 +4,8 @@ * * $Id$ */ - +#ifndef PDNS_GEOBACKEND_HH +#define PDNS_GEOBACKEND_HH #include #include @@ -110,3 +111,5 @@ public: }; static GeoLoader geoloader; + +#endif /* PDNS_GEOBACKEND_HH */ diff --git a/modules/geobackend/ippreftree.hh b/modules/geobackend/ippreftree.hh index 4e1bdca5c5..6278d68748 100644 --- a/modules/geobackend/ippreftree.hh +++ b/modules/geobackend/ippreftree.hh @@ -4,6 +4,8 @@ * * $Id$ */ +#ifndef PDNS_IPPREFTREE_HH +#define PDNS_IPPREFTREE_HH #include #include @@ -56,3 +58,5 @@ public: string reason; }; + +#endif /* PDNS_IPPREFTREE_HH */ diff --git a/modules/geoipbackend/geoipbackend.hh b/modules/geoipbackend/geoipbackend.hh index 0bb8560c1f..4c2e8acdf6 100644 --- a/modules/geoipbackend/geoipbackend.hh +++ b/modules/geoipbackend/geoipbackend.hh @@ -1,3 +1,6 @@ +#ifndef PDNS_GEOIPBACKEND_HH +#define PDNS_GEOIPBACKEND_HH + #include "config.h" #include "pdns/namespaces.hh" @@ -64,3 +67,5 @@ private: vector d_result; }; + +#endif /* PDNS_GEOIPBACKEND_HH */ diff --git a/modules/gmysqlbackend/gmysqlbackend.hh b/modules/gmysqlbackend/gmysqlbackend.hh index 4fbda4e49a..76a09db2fa 100644 --- a/modules/gmysqlbackend/gmysqlbackend.hh +++ b/modules/gmysqlbackend/gmysqlbackend.hh @@ -1,3 +1,6 @@ +#ifndef PDNS_GMYSQLBACKEND_HH +#define PDNS_GMYSQLBACKEND_HH + #include #include #include "pdns/backends/gsql/gsqlbackend.hh" @@ -11,3 +14,5 @@ class gMySQLBackend : public GSQLBackend public: gMySQLBackend(const string &mode, const string &suffix); //!< Makes our connection to the database. Throws an exception if it fails. }; + +#endif /* PDNS_GMYSQLBACKEND_HH */ diff --git a/modules/goraclebackend/goraclebackend.hh b/modules/goraclebackend/goraclebackend.hh index d8e9f6309d..ba98811200 100644 --- a/modules/goraclebackend/goraclebackend.hh +++ b/modules/goraclebackend/goraclebackend.hh @@ -1,3 +1,6 @@ +#ifndef PDNS_GORACLEBACKEND_HH +#define PDNS_GORACLEBACKEND_HH + #include #include #include "pdns/backends/gsql/gsqlbackend.hh" @@ -12,3 +15,5 @@ public: gOracleBackend(const string &mode, const string &suffix); //!< Makes our connection to the database. Throws an exception if it fails. virtual string sqlEscape(const string &name); }; + +#endif /* PDNS_GORACLEBACKEND_HH */ diff --git a/modules/gpgsqlbackend/gpgsqlbackend.hh b/modules/gpgsqlbackend/gpgsqlbackend.hh index b096d94fd3..e15953664b 100644 --- a/modules/gpgsqlbackend/gpgsqlbackend.hh +++ b/modules/gpgsqlbackend/gpgsqlbackend.hh @@ -1,3 +1,6 @@ +#ifndef PDNS_GPGSQLBACKEND_HH +#define PDNS_GPGSQLBACKEND_HH + #include #include #include "pdns/backends/gsql/gsqlbackend.hh" @@ -11,3 +14,5 @@ class gPgSQLBackend : public GSQLBackend public: gPgSQLBackend(const string &mode, const string &suffix); //!< Makes our connection to the database. Throws an exception if it fails. }; + +#endif /* PDNS_GPGSQLBACKEND_HH */ diff --git a/modules/lmdbbackend/lmdbbackend.hh b/modules/lmdbbackend/lmdbbackend.hh index 01f6ec8243..28c95b0b6e 100644 --- a/modules/lmdbbackend/lmdbbackend.hh +++ b/modules/lmdbbackend/lmdbbackend.hh @@ -2,6 +2,8 @@ * LMDBBackend - a high performance LMDB based backend for PowerDNS written by * Mark Zealey, 2013 */ +#ifndef PDNS_LMDBBACKEND_HH +#define PDNS_LMDBBACKEND_HH #include #include @@ -62,3 +64,5 @@ public: bool getAuthZone( string &rev_zone ); bool getAuthData( SOAData &, DNSPacket *); }; + +#endif /* PDNS_LMDBBACKEND_HH */ diff --git a/modules/oraclebackend/oraclebackend.hh b/modules/oraclebackend/oraclebackend.hh index 4119dd912e..e78e8ba50a 100644 --- a/modules/oraclebackend/oraclebackend.hh +++ b/modules/oraclebackend/oraclebackend.hh @@ -1,4 +1,3 @@ -// $Id$ /* * Copyright (c) 2010-2011 * @@ -7,6 +6,8 @@ * Karlsruhe Institute of Technology * */ +#ifndef PDNS_ORACLEBACKEND_HH +#define PDNS_ORACLEBACKEND_HH #include #include @@ -202,4 +203,4 @@ private: }; -/* vi: set sw=2 et : */ +#endif /* PDNS_ORACLEBACKEND_HH */ diff --git a/pdns/backends/gsql/gsqlbackend.hh b/pdns/backends/gsql/gsqlbackend.hh index e8acf757d1..165437f142 100644 --- a/pdns/backends/gsql/gsqlbackend.hh +++ b/pdns/backends/gsql/gsqlbackend.hh @@ -1,3 +1,6 @@ +#ifndef PDNS_GSQLBACKEND_HH +#define PDNS_GSQLBACKEND_HH + #include #include #include "ssql.hh" @@ -166,3 +169,5 @@ private: protected: bool d_dnssecQueries; }; + +#endif /* PDNS_GSQLBACKEND_HH */ diff --git a/pdns/comment.hh b/pdns/comment.hh index 1587d8b498..bb18fef382 100644 --- a/pdns/comment.hh +++ b/pdns/comment.hh @@ -19,7 +19,9 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#pragma once +#ifndef PDNS_COMMENT_HH +#define PDNS_COMMENT_HH + #include "utility.hh" #include "qtype.hh" #include @@ -38,3 +40,5 @@ public: string account; //!< account last updating this comment string content; //!< The actual comment. Example: blah blah }; + +#endif /* PDNS_COMMENT_HH */ diff --git a/pdns/pkcs11signers.hh b/pdns/pkcs11signers.hh index 37850ffeac..5fd5356fd4 100644 --- a/pdns/pkcs11signers.hh +++ b/pdns/pkcs11signers.hh @@ -1,3 +1,6 @@ +#ifndef PDNS_PKCS11SIGNERS_HH +#define PDNS_PKCS11SIGNERS_HH + class PKCS11DNSCryptoKeyEngine : public DNSCryptoKeyEngine { protected: @@ -48,3 +51,4 @@ class PKCS11DNSCryptoKeyEngine : public DNSCryptoKeyEngine static DNSCryptoKeyEngine* maker(unsigned int algorithm); }; +#endif /* PDNS_PKCS11SIGNERS_HH */ diff --git a/pdns/resolver.hh b/pdns/resolver.hh index 28fdb12a1b..0d457dd109 100644 --- a/pdns/resolver.hh +++ b/pdns/resolver.hh @@ -19,6 +19,8 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PDNS_RESOLVER_HH +#define PDNS_RESOLVER_HH #include #include @@ -145,3 +147,4 @@ public: } }; +#endif /* PDNS_RESOLVER_HH */ diff --git a/pdns/ws-api.hh b/pdns/ws-api.hh index 76cfc522fe..e8b7431381 100644 --- a/pdns/ws-api.hh +++ b/pdns/ws-api.hh @@ -19,6 +19,9 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PDNS_WSAPI_HH +#define PDNS_WSAPI_HH + #include #include "rapidjson/document.h" #include "rapidjson/stringbuffer.h" @@ -37,3 +40,5 @@ string apiZoneNameToId(const string& name); // To be provided by product code. void productServerStatisticsFetch(std::map& out); + +#endif /* PDNS_WSAPI_HH */ diff --git a/pdns/ws-recursor.hh b/pdns/ws-recursor.hh index 3f2fc845c1..90c9a362a2 100644 --- a/pdns/ws-recursor.hh +++ b/pdns/ws-recursor.hh @@ -19,6 +19,9 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PDNS_WSRECURSOR_HH +#define PDNS_WSRECURSOR_HH + #include #include "namespaces.hh" #include "mplexer.hh" @@ -68,3 +71,5 @@ public: private: AsyncWebServer* d_ws; }; + +#endif /* PDNS_WSRECURSOR_HH */ -- 2.47.2