]> git.ipfire.org Git - thirdparty/wireguard-tools.git/commitdiff
config: preserve const correctness
authorJason A. Donenfeld <Jason@zx2c4.com>
Mon, 23 Feb 2026 22:10:48 +0000 (23:10 +0100)
committerJason A. Donenfeld <Jason@zx2c4.com>
Mon, 23 Feb 2026 22:10:51 +0000 (23:10 +0100)
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
src/config.c

index 6b8aa58700ce7f5a7fb5fcb8c6f968674b734a83..806e3f825af37aba8ffb9d1ec8e39dd6a1ba0f71 100644 (file)
@@ -506,8 +506,9 @@ error:
 bool config_read_line(struct config_ctx *ctx, const char *input)
 {
        size_t len, cleaned_len = 0;
-       char *line, *comment;
+       const char *comment;
        bool ret = true;
+       char *line;
 
        /* This is what strchrnul is for, but that isn't portable. */
        comment = strchr(input, COMMENT_CHAR);