From 59a17888e96d748a119558e793ebb60d7f08a857 Mon Sep 17 00:00:00 2001 From: Lasse Collin Date: Thu, 8 Dec 2022 19:24:22 +0200 Subject: [PATCH] xz: Make args_info.files_name a const pointer. --- src/xz/args.c | 2 +- src/xz/args.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/xz/args.c b/src/xz/args.c index 7c327a5e..b0d63d69 100644 --- a/src/xz/args.c +++ b/src/xz/args.c @@ -490,7 +490,7 @@ parse_real(args_info *args, int argc, char **argv) "or `--files0'.")); if (optarg == NULL) { - args->files_name = (char *)stdin_filename; + args->files_name = stdin_filename; args->files_file = stdin; } else { args->files_name = optarg; diff --git a/src/xz/args.h b/src/xz/args.h index 46a8e8ed..a1a5930a 100644 --- a/src/xz/args.h +++ b/src/xz/args.h @@ -19,7 +19,7 @@ typedef struct { /// Name of the file from which to read filenames. This is NULL /// if --files or --files0 was not used. - char *files_name; + const char *files_name; /// File opened for reading from which filenames are read. This is /// non-NULL only if files_name is non-NULL.