From dd476a11320c3ab1cca088017fafe7925f5636e6 Mon Sep 17 00:00:00 2001
From: haozi007 <liuhao27@huawei.com>
Date: Sat, 27 May 2023 10:18:40 +0800
Subject: [PATCH 75/79] ensure define in local and use correctly type

Signed-off-by: haozi007 <liuhao27@huawei.com>
---
 src/cmd/isula/volume/prune.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/cmd/isula/volume/prune.c b/src/cmd/isula/volume/prune.c
index 2a3bca3e..c8d632ed 100644
--- a/src/cmd/isula/volume/prune.c
+++ b/src/cmd/isula/volume/prune.c
@@ -85,7 +85,6 @@ int cmd_volume_prune_main(int argc, const char **argv)
     command_t cmd;
     char **volumes = NULL;
     size_t volumes_len = 0;
-    char ch = 'n';
     struct command_option options[] = { LOG_OPTIONS(lconf) COMMON_OPTIONS(g_cmd_volume_prune_args)
         PRUNE_OPTIONS(g_cmd_volume_prune_args)
     };
@@ -113,6 +112,7 @@ int cmd_volume_prune_main(int argc, const char **argv)
     }
 
     if (!g_cmd_volume_prune_args.force) {
+        int ch;
         printf("WARNING! This will remove all local volumes not used by at least one container.\n");
         printf("Are you sure you want to continue? [y/N]");
         ch = getchar();
-- 
2.25.1

