From 20558212d7ca0476fe21879c8773fdff83807b59 Mon Sep 17 00:00:00 2001
From: zhangxiaoyu <zhangxiaoyu58@huawei.com>
Date: Tue, 6 Jun 2023 15:30:31 +0800
Subject: [PATCH 06/15] return non-zero if copy invalid

Signed-off-by: zhangxiaoyu <zhangxiaoyu58@huawei.com>
---
 src/cmd/isula/stream/cp.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/cmd/isula/stream/cp.c b/src/cmd/isula/stream/cp.c
index 2b0a79c7..f0cd99c9 100644
--- a/src/cmd/isula/stream/cp.c
+++ b/src/cmd/isula/stream/cp.c
@@ -302,9 +302,11 @@ static int client_run_copy(const struct client_arguments *args, const char *sour
 
     if (direction == AcrossContainers) {
         COMMAND_ERROR("copying between containers is not supported");
+        ret = -1;
         goto cleanup;
     }
 
+    ret = -1;
     COMMAND_ERROR("must specify at least one container source");
 
 cleanup:
-- 
2.25.1

