Commit 25d59cb2 authored by Andrei Vagin's avatar Andrei Vagin Committed by Pavel Emelyanov

crtools: fix exit code for page-server

cr_page_server() returns pid, if it is executed as a daemon
otherwise it returns an error code.

crtools returns 0 only if cr_page_server() returns a positive value,
what is obviously wrong.

travis-ci: success for crtools: close a signal descriptor after passing a preparation stage (rev6)
Signed-off-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
parent 68bfb80a
......@@ -775,7 +775,7 @@ int main(int argc, char *argv[], char *envp[])
}
if (!strcmp(argv[optind], "page-server"))
return cr_page_server(opts.daemon_mode, -1) > 0 ? 0 : 1;
return cr_page_server(opts.daemon_mode, -1) != 0;
if (!strcmp(argv[optind], "service"))
return cr_service(opts.daemon_mode);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment