Skip to content

Commit 79a2165

Browse files
Fixed incorrect exit code handling in cf-runagent
ChangeLog: Title Ticket: ENT-12712 Signed-off-by: Ihor Aleksandrychiev <ihor.aleksandrychiev@northern.tech>
1 parent 725bde1 commit 79a2165

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cf-runagent/cf-runagent.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ int main(int argc, char *argv[])
266266
if (fork() == 0) /* child process */
267267
{
268268
int remote_exit_code = HailServer(ctx, config, RlistScalarValue(rp));
269-
DoCleanupAndExit(remote_exit_code > 0 ? remote_exit_code : CF_RA_EXIT_CODE_OTHER_ERR);
269+
DoCleanupAndExit(remote_exit_code >= 0 ? remote_exit_code : CF_RA_EXIT_CODE_OTHER_ERR);
270270
}
271271
else /* parent process */
272272
{

0 commit comments

Comments
 (0)