Replace perror() with warn()

This commit is contained in:
Julien Danjou 2008-03-10 09:26:20 +01:00
parent edc0c01f2b
commit 28af9e7e61
1 changed files with 3 additions and 3 deletions

View File

@ -349,12 +349,12 @@ main(int argc, char *argv[])
if(errno == EADDRINUSE) if(errno == EADDRINUSE)
{ {
if(unlink(addr->sun_path)) if(unlink(addr->sun_path))
perror("error unlinking existing file"); warn("error unlinking existing file: %s\n", strerror(errno));
if(bind(csfd, (const struct sockaddr *) addr, SUN_LEN(addr))) if(bind(csfd, (const struct sockaddr *) addr, SUN_LEN(addr)))
perror("error binding UNIX domain socket"); warn("error binding UNIX domain socket: %s\n", strerror(errno));
} }
else else
perror("error binding UNIX domain socket"); warn("error binding UNIX domain socket: %s\n", strerror(errno));
} }
/* register function for signals */ /* register function for signals */