On 01/09/2012 10:18 AM, Lucas Fialho Zawacki wrote:
From: Lucas Fialho Zawackilfzawacki@gmail.com
- /* Set username in device */
- HeapFree(GetProcessHeap(), 0, This->username);
- This->username = HeapAlloc(GetProcessHeap(), 0, sizeof(WCHAR) * (lstrlenW(username) + 1));
- lstrcpyW(This->username, username);
No error checking if allocation fails.
- /* Free username */
- HeapFree(GetProcessHeap(), 0, This->username);
Comment is kind of redundant the property already called "username".
Vitaliy.