extensions/roleplay: Fix memory leak on every use.
This commit is contained in:
parent
b45b2daef9
commit
a6b29d3ed4
1 changed files with 3 additions and 1 deletions
|
@ -138,10 +138,12 @@ m_displaymsg(struct Client *source_p, const char *channel, int underline, int ac
|
||||||
struct Channel *chptr;
|
struct Channel *chptr;
|
||||||
struct membership *msptr;
|
struct membership *msptr;
|
||||||
char nick2[NICKLEN+1];
|
char nick2[NICKLEN+1];
|
||||||
char *nick3 = rb_strdup(nick);
|
char nick3[NICKLEN+1];
|
||||||
char text3[BUFSIZE];
|
char text3[BUFSIZE];
|
||||||
char text2[BUFSIZE];
|
char text2[BUFSIZE];
|
||||||
|
|
||||||
|
rb_strlcpy(nick3, nick, sizeof nick3);
|
||||||
|
|
||||||
if(!IsFloodDone(source_p))
|
if(!IsFloodDone(source_p))
|
||||||
flood_endgrace(source_p);
|
flood_endgrace(source_p);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue