diff --git a/src/s_serv.c b/src/s_serv.c index 32367cf5b..90f2c6c25 100644 --- a/src/s_serv.c +++ b/src/s_serv.c @@ -430,7 +430,8 @@ burst_ban(struct Client *client_p) */ rb_strlcpy(operbuf, aconf->info.oper, sizeof buf); p = strrchr(operbuf, '{'); - if (operbuf + sizeof operbuf - p > (ptrdiff_t)(melen + 2)) + if (p != NULL && + operbuf + sizeof operbuf - p > (ptrdiff_t)(melen + 2)) { memcpy(p + 1, me.name, melen); p[melen + 1] = '}';