Skip to content

Commit

Permalink
daemon: unix socket checking before creating new
Browse files Browse the repository at this point in the history
+ unix socket spamming removed

Signed-off-by: LUU QUANG MINH <[email protected]>
  • Loading branch information
LUU QUANG MINH authored and LUU QUANG MINH committed Dec 30, 2024
1 parent 8fc4e8e commit a01d5e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/daemon/dlt_daemon_unix_socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ int dlt_daemon_unix_socket_open(int *sock, char *sock_path, int type, int mask)
addr.sun_family = AF_UNIX;
memcpy(addr.sun_path, sock_path, sizeof(addr.sun_path));

if (unlink(sock_path) != 0) {
if(unlink(sock_path) != 0 && (errno != ENOENT)) {
dlt_vlog(LOG_WARNING, "%s: unlink() failed: %s\n",
__func__, strerror(errno));
}
Expand Down

0 comments on commit a01d5e9

Please sign in to comment.