Is there anything wrong with this patch ? I think this one is a real memory leak.
"WaitNamedPipeW" in dlls/kernel32/sync.c gets flagged by Michael Stefaniuc's unfree-wine.pl script for leaking "pipe_wait".
pipe_wait isn't used anywhere between its allocation and the memory leak in the error path. nt_name.Length, which is used for computing sz_pipe_wait isn't modified either in those lines. Therefore, I fixed the leak in the error path by moving the allocation later in the program.
2007-10-06 Lionel Debroux lionel_debroux@yahoo.fr * dlls/kernel32/sync.c: kernel32: fix memory leak (found by Smatch).
_____________________________________________________________________________ Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail
Lionel Debroux lionel_debroux@yahoo.fr writes:
Is there anything wrong with this patch ? I think this one is a real memory leak.
nt_name is still leaked, and now you are leaking a file handle too. You really need to be more careful with these fixes.