Browse Source

Use memmem in place of strnstr

master
Causal Agent 7 months ago
parent
commit
5fcd801783
Signed by: Curtis McEnroe <june@causal.agency> GPG Key ID: CEA2F97ADCFCD77C
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      irc.c

+ 1
- 1
irc.c View File

@@ -140,7 +140,7 @@ retry:

char *crlf;
char *line = buf;
while (NULL != (crlf = strnstr(line, "\r\n", &buf[len] - line))) {
while (NULL != (crlf = memmem(line, &buf[len] - line, "\r\n", 2))) {
crlf[0] = '\0';
if (self.raw) {
uiFmt(TagRaw, UICold, "\3%d>>>\3 %s", IRCGray, line);

Loading…
Cancel
Save