From: Jouni Malinen Date: Tue, 10 Nov 2009 15:05:28 +0000 (+0200) Subject: Fix use-after-free issue with pid_file in hostapd termination X-Git-Tag: hostap_0_7_0~80 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=libeap.git;a=commitdiff_plain;h=dd745de384a5d6398b62a2737f2b6bd581495de7 Fix use-after-free issue with pid_file in hostapd termination --- diff --git a/hostapd/main.c b/hostapd/main.c index b582b2d..8bcc745 100644 --- a/hostapd/main.c +++ b/hostapd/main.c @@ -460,13 +460,13 @@ int main(int argc, char *argv[]) ret = 0; out: - os_free(pid_file); /* Deinitialize all interfaces */ for (i = 0; i < interfaces.count; i++) hostapd_interface_deinit(interfaces.iface[i]); os_free(interfaces.iface); hostapd_global_deinit(pid_file); + os_free(pid_file); return ret; }