return EXIT_FAILURE on failure

This commit is contained in:
Julien Danjou 2007-10-29 16:20:11 +01:00
parent 78b3dab63e
commit c8e489d4c9
1 changed files with 3 additions and 0 deletions

View File

@ -39,6 +39,9 @@ main()
csfd = get_client_socket();
addr = get_client_addr();
if(!addr || csfd < 0)
return EXIT_FAILURE;
while(fgets(buf, sizeof(buf), stdin))
if(sendto(csfd, buf, a_strlen(buf), MSG_NOSIGNAL,
(const struct sockaddr *) addr, sizeof(struct sockaddr_un)) == -1)