[PATCH] programs/ping: add IcmpCloseHandle(icmp_file) and fix a memory leak.
22 Dec
22 Dec
11:15 a.m.
"Jiangyi Chen" <cjy520lcy(a)163.com> writes:
@@ -218,6 +218,12 @@ int __cdecl main(int argc, char** argv) min, max, avg); }
+ if(icmp_file != INVALID_HANDLE_VALUE) + { + IcmpCloseHandle(icmp_file); + icmp_file = INVALID_HANDLE_VALUE; + } + if(send_data) heap_free(send_data);
There's no reason to bother closing handles or freeing data when the process is exiting anyway. -- Alexandre Julliard julliard(a)winehq.org
1815
Age (days ago)
1815
Last active (days ago)
1 comments
2 participants
participants (2)
-
Alexandre Julliard -
Jiangyi Chen