1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

Patch from waider to set exit code of last executed command specified

as an argument to -c.
(This used to be commit 048aeefcdc)
This commit is contained in:
Tim Potter 2003-04-23 07:10:28 +00:00
parent f3f78bb9b4
commit 1fe7ec8b4b

View File

@ -628,13 +628,15 @@ out_free:
if (cmdstr && cmdstr[0]) {
char *cmd;
char *p = cmdstr;
int result = 0;
while((cmd=next_command(&p)) != NULL) {
process_cmd(cli, cmd);
NTSTATUS cmd_result = process_cmd(cli, cmd);
result = NT_STATUS_IS_ERR(cmd_result);
}
cli_shutdown(cli);
return 0;
return result;
}
/* Loop around accepting commands */