]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/dnsqueue.cpp
Forward port of CullList and my bragging rights
[user/henk/code/inspircd.git] / src / dnsqueue.cpp
index 73d80d11d02804b3fc526979d49dc7e560a7dc60..975884796f7dd24f9963c58dfb98cc77b9257077 100644 (file)
@@ -111,8 +111,8 @@ public:
                                                {
                                                        if ((std::string((char*)inet_ntoa(usr->ip4)) == ip) && (hostname.length() < 65))
                                                        {
-                                                               strlcpy(usr->host,hostname.c_str(),MAXBUF);
-                                                               strlcpy(usr->dhost,hostname.c_str(),MAXBUF);
+                                                               strlcpy(usr->host,hostname.c_str(),64);
+                                                               strlcpy(usr->dhost,hostname.c_str(),64);
                                                                /*address_cache::iterator address = addrcache.find(usr->ip4);
                                                                if (address == addrcache.end())
                                                                {
@@ -247,7 +247,7 @@ void dns_poll(int fdcheck)
                                 * from the socket engine, as dns.cpp tracks it
                                 * for us if we are in single-threaded country.
                                 */
-                               delete x;
+                               DELETE(x);
                        }
                }
                else
@@ -255,7 +255,7 @@ void dns_poll(int fdcheck)
                        /* its fd is dodgy, the dns code probably
                         * bashed it due to error. Free the class.
                         */
-                       delete x;
+                       DELETE(x);
                }
                /* If we got down here, the dns lookup was valid, BUT,
                 * its still in progress. Be patient, and wait for