- if (EmptyString(password))
- return need_more_params(cptr, "PASS");
-
- /* TODO: For protocol negotiation */
-#if 0
- if (ircd_strcmp(password,"PROT")==0) {
- /* Do something here */
+ /* Some clients (brokenly) send "PASS x y" rather than "PASS :x y"
+ * when the user enters "x y" as the password. Unsplit arguments to
+ * work around this.
+ */
+ for (arg = 1, len = 0; arg < parc; ++arg)
+ {
+ ircd_strncpy(password + len, parv[arg], sizeof(password) - len);
+ len += strlen(parv[arg]);
+ password[len++] = ' ';