mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-02-16 09:03:05 -05:00
EAP-SIM DB: Fix a memory leak on DB connection re-opening
Signed-hostap: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
704b8762a2
commit
c13f0a3e00
@ -340,6 +340,7 @@ static int eap_sim_db_open_socket(struct eap_sim_db_data *data)
|
||||
addr.sun_family = AF_UNIX;
|
||||
os_snprintf(addr.sun_path, sizeof(addr.sun_path),
|
||||
"/tmp/eap_sim_db_%d-%d", getpid(), counter++);
|
||||
os_free(data->local_sock);
|
||||
data->local_sock = os_strdup(addr.sun_path);
|
||||
if (bind(data->sock, (struct sockaddr *) &addr, sizeof(addr)) < 0) {
|
||||
perror("bind(eap_sim_db)");
|
||||
|
Loading…
x
Reference in New Issue
Block a user