Explorar o código

ims_ipsec_pcscf: fix non-close mnl_socket when a bind error

Stanislav S. Litvinenko %!s(int64=5) %!d(string=hai) anos
pai
achega
8cae623c70
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      src/modules/ims_ipsec_pcscf/ipsec.c

+ 1 - 0
src/modules/ims_ipsec_pcscf/ipsec.c

@@ -63,6 +63,7 @@ struct mnl_socket* init_mnl_socket()
 
     if(mnl_socket_bind(mnl_socket, 0, MNL_SOCKET_AUTOPID) < 0) {
         LM_ERR("Error binding a MNL socket\n");
+        close_mnl_socket(mnl_socket);
         return NULL;
     }