diff --git a/src/client.c b/src/client.c index 43b80b1..9979ce4 100644 --- a/src/client.c +++ b/src/client.c @@ -53,7 +53,7 @@ int main(int argc, char **argv) { char socket_filename[108]; snprintf(socket_filename, sizeof(socket_filename), - UNIX_SOCKET_HANDLER_SOCKET_FMT_STRING, getenv("HOME")); + UNIX_SOCKET_HANDLER_SOCKET_FMT_STRING, getenv("USER")); struct sockaddr_un addr; int ret; diff --git a/src/socket.c b/src/socket.c index 43a5f0a..a1c2c95 100644 --- a/src/socket.c +++ b/src/socket.c @@ -115,7 +115,7 @@ void init_unix_socket_handler(UnixSocketHandler *handler) { memset(handler, 0, sizeof(UnixSocketHandler)); snprintf(handler->socket_filename, sizeof(handler->socket_filename), - UNIX_SOCKET_HANDLER_SOCKET_FMT_STRING, getenv("HOME")); + UNIX_SOCKET_HANDLER_SOCKET_FMT_STRING, getenv("USER")); umask(S_IRWXO);