]> PatchyGit - patchyircd.git/commitdiff
irc.c: fix goto crossing initialization of res
authorEgor <egor@patchysicp.xyz>
Tue, 21 Jan 2025 03:39:33 +0000 (05:39 +0200)
committerEgor <egor@patchysicp.xyz>
Tue, 21 Jan 2025 03:39:33 +0000 (05:39 +0200)
src/irc.c

index 7609d8a..de6a298 100644 (file)
--- a/src/irc.c
+++ b/src/irc.c
@@ -410,7 +410,8 @@ int processPacket(struct client_data *client, char *source, char *command, int a
                                }
                                client->saslbuf[client->saslbufLen] = '\0';
                                const char *username;
-                               int res = -1;
+                               int res;
+                               res = -1;
                                if (!client->saslexternal) {
                                        username = strchr(client->saslbuf, '\0')+1;
                                        if (username > client->saslbuf + client->saslbufLen)