Date: Fri, 28 Jan 2022 09:17:37 GMT From: Baptiste Daroussin <bapt@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: f95498601547 - main - disextract: eliminate last use of __DECONST Message-ID: <202201280917.20S9HbtL052473@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=f95498601547f7aeb76426fb3282b51ceb59eb6f commit f95498601547f7aeb76426fb3282b51ceb59eb6f Author: Baptiste Daroussin <bapt@FreeBSD.org> AuthorDate: 2022-01-28 09:09:08 +0000 Commit: Baptiste Daroussin <bapt@FreeBSD.org> CommitDate: 2022-01-28 09:09:08 +0000 disextract: eliminate last use of __DECONST --- usr.sbin/bsdinstall/distextract/distextract.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.sbin/bsdinstall/distextract/distextract.c b/usr.sbin/bsdinstall/distextract/distextract.c index 81931e7cf50d..f7f973fe336c 100644 --- a/usr.sbin/bsdinstall/distextract/distextract.c +++ b/usr.sbin/bsdinstall/distextract/distextract.c @@ -46,7 +46,7 @@ __FBSDID("$FreeBSD$"); #include <unistd.h> /* Data to process */ -static char *distdir = NULL; +static const char *distdir = NULL; static struct archive *archive = NULL; /* Function prototypes */ @@ -74,7 +74,7 @@ main(void) if ((distributions = getenv("DISTRIBUTIONS")) == NULL) errx(EXIT_FAILURE, "DISTRIBUTIONS variable is not set"); if ((distdir = getenv("BSDINSTALL_DISTDIR")) == NULL) - distdir = __DECONST(char *, ""); + distdir = ""; if ((distribs = strdup(distributions)) == NULL) errx(EXIT_FAILURE, "memory error"); @@ -128,7 +128,7 @@ main(void) snprintf(error, sizeof(error), "Could not change to directory %s: %s\n", chrootdir, strerror(errno)); - conf.title = __DECONST(char *, "Error"); + conf.title = "Error"; bsddialog_msgbox(&conf, error, 0, 0); bsddialog_end(); return (EXIT_FAILURE);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202201280917.20S9HbtL052473>