m_dline: Make error notices more verbose

This commit is contained in:
Ed Kellett 2020-07-26 18:17:01 +01:00
parent bf493a3410
commit 72464c6abd
No known key found for this signature in database
GPG key ID: CB9986DEF342FABC

View file

@ -99,14 +99,14 @@ mo_dline(struct MsgBuf *msgbuf_p, struct Client *client_p, struct Client *source
/* would break the protocol */
if (*dlhost == ':')
{
sendto_one_notice(source_p, ":Invalid D-Line");
sendto_one_notice(source_p, ":Invalid D-Line [%s] - IP cannot start with :", dlhost);
return;
}
int ty = parse_netmask_strict(dlhost, NULL, NULL);
if (ty != HM_IPV4 && ty != HM_IPV6)
{
sendto_one_notice(source_p, ":Invalid D-Line");
sendto_one_notice(source_p, ":Invalid D-Line [%s] - doesn't look like IP[/cidr]", dlhost);
return;
}
@ -366,7 +366,7 @@ apply_undline(struct Client *source_p, const char *cidr)
if(masktype != HM_IPV4 && masktype != HM_IPV6)
{
sendto_one_notice(source_p, ":Invalid D-Line");
sendto_one_notice(source_p, ":Invalid D-Line [%s] - doesn't look like IP[/cidr]", cidr);
return;
}