diff --git a/page-xfer.c b/page-xfer.c index e409dba43..f56448c73 100644 --- a/page-xfer.c +++ b/page-xfer.c @@ -307,8 +307,9 @@ int cr_page_server(bool daemon_mode, int cfd) no_server: if (daemon_mode) { ret = cr_daemon(1, 0, &ask, cfd); + close_safe(&sk); if (ret == -1) { - pr_perror("Can't run in the background"); + pr_err("Can't run in the background\n"); goto out; } if (ret > 0) { /* parent task, daemon started */