From d947ff2d2b2b057993f1611075c218fbbb1e11bc Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Wed, 13 Apr 2022 17:21:39 -0700 Subject: [PATCH] gvpack: cast assignment of string literal to 'rhs' This pre-emptively squashes an upcoming warning when converting this file to C++ which otherwise fails the CMake build: cmd/tools/gvpack.cpp:122:17: error: ISO C++11 does not allow conversion from string literal to 'char *' [-Werror,-Wwritable-strings] Gitlab: #2154 --- cmd/tools/gvpack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/tools/gvpack.c b/cmd/tools/gvpack.c index 8e7687705..5c57a6ef5 100644 --- a/cmd/tools/gvpack.c +++ b/cmd/tools/gvpack.c @@ -119,7 +119,7 @@ static FILE *openFile(const char *name) static int setNameValue(char *arg) { char *p; - char *rhs = "true"; + char *rhs = (char*)"true"; if ((p = strchr(arg, '='))) { *p++ = '\0'; -- 2.40.0