Don't warn on cleanup unlink error

We may catch an exit signal before we actually bound to the socket.
This commit is contained in:
Quentin Rameau 2017-07-24 00:56:43 +02:00 committed by Laslo Hunhold
parent 24167b5c07
commit 1a0eca12a5

View file

@ -894,9 +894,8 @@ static void
cleanup(void) cleanup(void)
{ {
close(insock); close(insock);
if (udsname) { if (udsname)
if (unlink(udsname) < 0) unlink(udsname);
fprintf(stderr, "unlink: %s\n", strerror(errno));
} }
static void static void