Skip to content
Snippets Groups Projects
Commit 546a0d80 authored by Fredrik Thulin's avatar Fredrik Thulin
Browse files

Don't try to unlink() non-UNIX socket paths.

parent d114f87a
No related branches found
No related tags found
No related merge requests found
......@@ -2601,7 +2601,9 @@ void gck_rpc_layer_uninitialize(void)
pkcs11_socket = -1;
/* Delete our unix socket */
if (pkcs11_socket_path[0])
if (pkcs11_socket_path[0] &&
strncmp(pkcs11_socket_path, "tcp://", strlen("tcp://")) != 0 &&
strncmp(pkcs11_socket_path, "tls://", strlen("tls://")) != 0)
unlink(pkcs11_socket_path);
pkcs11_socket_path[0] = 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment