]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
More const fixes
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Fri, 15 May 2026 20:17:12 +0000 (14:17 -0600)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Fri, 15 May 2026 20:17:12 +0000 (14:17 -0600)
src/bin/radclient.c
src/bin/unit_test_attribute.c

index 05282cc0e0a9840b81fc4bdb435f6b44f63c76aa..8793b131a01e16bcff3cc795cd1e04b74fec0dab 100644 (file)
@@ -1812,14 +1812,14 @@ int main(int argc, char **argv)
                                /*
                                 *      Look for CoA filename
                                 */
-                               q = strchr(files->filters, c);
+                               q = UNCONST(char *, strchr(files->filters, c));
                                if (q) {
                                        do_coa = true;
 
                                        *(q++) = '\0';
                                        files->coa_reply = q;
 
-                                       q = strchr(files->coa_reply, c);
+                                       q = UNCONST(char *, strchr(files->coa_reply, c));
                                        if (q) {
                                                *(q++) = '\0';
                                                files->coa_filter = q;
index 79329887b27fcc9275ae9588d2384410828ed63a..3580019ba1609b061c30e31bffdda55ae76f71c2 100644 (file)
@@ -4264,11 +4264,11 @@ static int process_path(bool *exit_now, TALLOC_CTX *ctx, command_config_t const
         */
        if ((receipt_dir || receipt_file) &&
            (strncmp(path, "src/tests/unit/", 15) == 0)) {
-               p = strchr(path + 15, '/');
+               p = UNCONST(char *, strchr(path + 15, '/'));
                if (!p) {
                        printf("UNIT-TEST %s\n", path + 15);
                } else {
-                       char *q = strchr(p + 1, '/');
+                       char *q = UNCONST(char *, strchr(p + 1, '/'));
 
                        *p = '\0';