From 931097811c8e33ec0c42bd8b4f57ae0a35ae3fed Mon Sep 17 00:00:00 2001 From: arturoc Date: Fri, 12 Jul 2013 15:36:12 +0200 Subject: [PATCH] win32_window.c: don't memset the whole buffer --- src/win32_window.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/win32_window.c b/src/win32_window.c index 2db4c498..1d1dc0d0 100644 --- a/src/win32_window.c +++ b/src/win32_window.c @@ -730,12 +730,12 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg, // Retrieve the names of the dropped objects int count = DragQueryFile(hDrop, 0xFFFFFFFF, szName, MAX_PATH); char s[MAX_PATH*count]; - memset(s,0,sizeof(s)); + s[0] = 0; int i; for(i = 0; i < count; i++) { DragQueryFile(hDrop, i, szName, MAX_PATH); - char* utf8str = _glfwCreateUTF8FromWideString((const wchar_t*)szName) + char* utf8str = _glfwCreateUTF8FromWideString((const wchar_t*)szName); strcat(s, utf8str); strcat(s, "\n"); free(utf8str);