Skip to content

Commit 437a2f5

Browse files
committed
irc.c: Fix unused-but-set-variable errors in gcc 16.
1 parent f7e97dd commit 437a2f5

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

irc.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -397,12 +397,10 @@ void irc_loop(struct irc_client *client, FILE *logfile, void (*cb)(void *data, s
397397
char *prevbuf, *mybuf = readbuf;
398398
size_t prevlen, mylen = sizeof(readbuf) - 1;
399399
char *start, *eom;
400-
int rounds;
401400

402401
start = readbuf;
403402
for (;;) {
404403
begin:
405-
rounds = 0;
406404
if (mylen <= 1) {
407405
/* IRC max message is 512, but we could have received multiple messages in one read() */
408406
char *a;
@@ -463,7 +461,6 @@ void irc_loop(struct irc_client *client, FILE *logfile, void (*cb)(void *data, s
463461

464462
mylen -= (unsigned long) (eom + 2 - mybuf);
465463
start = mybuf = eom + 2;
466-
rounds++;
467464
} while (mybuf && *mybuf);
468465

469466
start = mybuf = readbuf; /* Reset to beginning */
@@ -690,7 +687,7 @@ static int irc_client_nickserv_login(struct irc_client *client, const char *user
690687

691688
/* Confused about the difference between the two? See https://stackoverflow.com/questions/31666247/ */
692689
res |= irc_send(client, "PRIVMSG NickServ :IDENTIFY %s %s", username, password); /* Actual IRC nickname */
693-
return 0;
690+
return res;
694691
}
695692

696693
static int wait_for_response(struct irc_client *client, char *buf, size_t len, int ms, const char *s)

0 commit comments

Comments
 (0)