1
0
mirror of https://github.com/anope/anope.git synced 2026-07-06 14:53:13 +02:00

Fix some coding style issues.

This commit is contained in:
Sadie Powell
2024-02-26 15:27:01 +00:00
parent e341cac8d6
commit c6cb4ba159
78 changed files with 195 additions and 195 deletions
+2 -2
View File
@@ -46,13 +46,13 @@ struct BadWords
* @param type The type (SINGLE START END)
* @return The badword
*/
virtual BadWord* AddBadWord(const Anope::string &word, BadWordType type) = 0;
virtual BadWord *AddBadWord(const Anope::string &word, BadWordType type) = 0;
/** Get a badword structure by index
* @param index The index
* @return The badword
*/
virtual BadWord* GetBadWord(unsigned index) const = 0;
virtual BadWord *GetBadWord(unsigned index) const = 0;
/** Get how many badwords are on this channel
* @return The number of badwords in the vector
+1 -1
View File
@@ -33,5 +33,5 @@ public:
delete (*this)->at(i - 1);
}
virtual EntryMsg* Create() = 0;
virtual EntryMsg *Create() = 0;
};
+4 -4
View File
@@ -27,9 +27,9 @@ struct HTTPReply final
std::vector<cookie> cookies;
HTTPReply() = default;
HTTPReply& operator=(const HTTPReply &) = default;
HTTPReply &operator=(const HTTPReply &) = default;
HTTPReply(const HTTPReply& other) : error(other.error), length(other.length)
HTTPReply(const HTTPReply &other) : error(other.error), length(other.length)
{
content_type = other.content_type;
headers = other.headers;
@@ -169,7 +169,7 @@ public:
virtual bool RegisterPage(HTTPPage *page) = 0;
virtual void UnregisterPage(HTTPPage *page) = 0;
virtual HTTPPage* FindPage(const Anope::string &name) = 0;
virtual HTTPPage *FindPage(const Anope::string &name) = 0;
};
namespace HTTPUtils
@@ -180,7 +180,7 @@ namespace HTTPUtils
for (unsigned i = 0; i < url.length(); ++i)
{
const char& c = url[i];
const char &c = url[i];
if (c == '%' && i + 2 < url.length())
{
+1 -1
View File
@@ -78,5 +78,5 @@ class CertService
public:
CertService(Module *c) : Service(c, "CertService", "certs") { }
virtual NickCore* FindAccountFromCert(const Anope::string &cert) = 0;
virtual NickCore *FindAccountFromCert(const Anope::string &cert) = 0;
};
+1 -1
View File
@@ -41,7 +41,7 @@ public:
virtual void RemoveForbid(ForbidData *d) = 0;
virtual ForbidData* CreateForbid() = 0;
virtual ForbidData *CreateForbid() = 0;
virtual ForbidData *FindForbid(const Anope::string &mask, ForbidType type) = 0;
+2 -2
View File
@@ -29,7 +29,7 @@ struct Exception final
Exception() : Serializable("Exception") { }
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &data);
static Serializable *Unserialize(Serializable *obj, Serialize::Data &data);
};
class SessionService
@@ -70,7 +70,7 @@ void Exception::Serialize(Serialize::Data &data) const
data["expires"] << this->expires;
}
Serializable* Exception::Unserialize(Serializable *obj, Serialize::Data &data)
Serializable *Exception::Unserialize(Serializable *obj, Serialize::Data &data)
{
if (!session_service)
return NULL;
+2 -2
View File
@@ -32,7 +32,7 @@ namespace SASL
virtual Anope::string GetAgent() = 0;
virtual Session* GetSession(const Anope::string &uid) = 0;
virtual Session *GetSession(const Anope::string &uid) = 0;
virtual void SendMessage(SASL::Session *session, const Anope::string &type, const Anope::string &data) = 0;
@@ -67,7 +67,7 @@ namespace SASL
public:
Mechanism(Module *o, const Anope::string &sname) : Service(o, "SASL::Mechanism", sname) { }
virtual Session* CreateSession(const Anope::string &uid) { return new Session(this, uid); }
virtual Session *CreateSession(const Anope::string &uid) { return new Session(this, uid); }
virtual void ProcessMessage(Session *session, const Message &) = 0;
+3 -3
View File
@@ -24,7 +24,7 @@ namespace SQL
Clear();
}
std::iostream& operator[](const Anope::string &key) override
std::iostream &operator[](const Anope::string &key) override
{
std::stringstream *&ss = data[key];
if (!ss)
@@ -107,7 +107,7 @@ namespace SQL
Query() { }
Query(const Anope::string &q) : query(q) { }
Query& operator=(const Anope::string &q)
Query &operator=(const Anope::string &q)
{
this->query = q;
this->parameters.clear();
@@ -124,7 +124,7 @@ namespace SQL
return !(*this == other);
}
template<typename T> void SetValue(const Anope::string &key, const T& value, bool escape = true)
template<typename T> void SetValue(const Anope::string &key, const T &value, bool escape = true)
{
try
{
+1 -1
View File
@@ -18,7 +18,7 @@ public:
Anope::string name;
Anope::string id;
std::deque<Anope::string> data;
HTTPReply& r;
HTTPReply &r;
XMLRPCRequest(HTTPReply &_r) : r(_r) { }
inline void reply(const Anope::string &dname, const Anope::string &ddata) { this->replies.emplace(dname, ddata); }