eio_monitor: fix memory leak in eio monitor module

Summary:
Free the allocated memory in eio monitor win32 module.

Signed-off-by: Vivek Ellur <vivek.ellur@samsung.com>

Reviewers: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3160

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
This commit is contained in:
Vivek Ellur 2015-10-08 12:17:29 +02:00 committed by Cedric BAIL
parent 491fdb94b0
commit d64f50acfc
1 changed files with 4 additions and 1 deletions

View File

@ -86,7 +86,10 @@ _eio_monitor_win32_cb(void *data, Ecore_Win32_Handler *wh EINA_UNUSED)
return 0;
if (fni->FileName[0] == 0)
return ECORE_CALLBACK_CANCEL;
{
free(wname);
return ECORE_CALLBACK_CANCEL;
}
memcpy(wname, fni->FileName, fni->FileNameLength);
wname[fni->FileNameLength / sizeof(wchar_t)] = 0;