Remove build warning messages 37/281337/2
authorHwankyu Jhun <h.jhun@samsung.com>
Thu, 15 Sep 2022 10:47:54 +0000 (10:47 +0000)
committerHwankyu Jhun <h.jhun@samsung.com>
Thu, 15 Sep 2022 10:49:17 +0000 (10:49 +0000)
To remove -Wwrite-strings warning messages, char array is added to set
the SERVER_BIN.

Change-Id: I66cb1c3d325f794f6d89b66b378b2f0f15836297
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
benchmark/tool/main.cc

index a8b5ce8..580eb69 100644 (file)
@@ -147,7 +147,8 @@ class Tester {
     if (server_pid_ == 0) {
       setsid();
 
-      char* argv[] = { SERVER_BIN, nullptr, nullptr };
+      char bin[] = { SERVER_BIN };
+      char* argv[] = { bin, nullptr, nullptr };
       int ret = execv(argv[0], argv);
       if (ret < 0) {
         std::cerr << "execv() is failed. errno: " << errno << std::endl;