From ce7d58a8a8626300b4b6861e54cf23db526b0e8b Mon Sep 17 00:00:00 2001 From: Herb Lewis Date: Sat, 13 Dec 2008 12:18:15 -0800 Subject: [PATCH] don't return 0 on error - bad for scripts (cherry picked from commit 79d68083411e9119933dbf5c850cb78f47e6f553) --- source/utils/smbcacls.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/utils/smbcacls.c b/source/utils/smbcacls.c index 1bfc4757da3..f7f12722158 100644 --- a/source/utils/smbcacls.c +++ b/source/utils/smbcacls.c @@ -735,6 +735,8 @@ static int owner_set(struct cli_state *cli, enum chown_mode change_mode, if (!cli_set_secdesc(cli, fnum, sd)) { printf("ERROR: secdesc set failed: %s\n", cli_errstr(cli)); + cli_close(cli, fnum); + return EXIT_FAILED; } cli_close(cli, fnum); -- 2.11.4.GIT