]> arthur.barton.de Git - ngircd-alex.git/blobdiff - src/ngircd/irc-login.c
Merge branches 'CloakUserHost', 'QuitOnHTTP' and 'bug72-WHOIS-List'
[ngircd-alex.git] / src / ngircd / irc-login.c
index 518c9f1d605207a7128ce26b37ae63bab295703b..92d54ab15e42ad64d2e7d05bd605bccc1cd7f734 100644 (file)
@@ -683,13 +683,28 @@ IRC_QUIT( CLIENT *Client, REQUEST *Req )
 } /* IRC_QUIT */
 
 
+#ifndef STRICT_RFC
+
+/**
+ * Handler for HTTP command, e.g. GET and POST
+ *
+ * We handle these commands here to avoid the quite long timeout when
+ * some user tries to access this IRC daemon using an web browser ...
+ *
+ * @param Client       The client from which this command has been received.
+ * @param Req          Request structure with prefix and all parameters.
+ * @returns            CONNECTED or DISCONNECTED.
+ */
 GLOBAL bool
 IRC_QUIT_HTTP( CLIENT *Client, REQUEST *Req )
 {
-       Req->argc = 0;
+       Req->argc = 1;
+       Req->argv[0] = "Oops, HTTP request received? This is IRC!";
        return IRC_QUIT(Client, Req);
 } /* IRC_QUIT_HTTP */
 
+#endif
+
 
 /**
  * Handler for the IRC "PING" command.