opt: handle -Wcast-qual warnings.
[ccan] / ccan / opt / test / run-helpers.c
index f85c73c4e9f10ad8e2d8e8ea9c8c4a5d2f25dfff..de60ac9ff08e4fbac8e46943fe36e404f2301361 100644 (file)
@@ -122,7 +122,7 @@ int main(int argc, char *argv[])
        }
        /* opt_set_charp */
        {
-               char *arg = (char *)"wrong";
+               char *arg = cast_const(char *, "wrong");
                reset_options();
                opt_register_arg("-a", opt_set_charp, NULL, &arg, "All");
                ok1(parse_args(&argc, &argv, "-a", "string", NULL));