diff --git a/plugins/win-capture/window-helpers.c b/plugins/win-capture/window-helpers.c index 52a85a6e2..983e32400 100644 --- a/plugins/win-capture/window-helpers.c +++ b/plugins/win-capture/window-helpers.c @@ -124,7 +124,7 @@ static void get_window_class(struct dstr *class, HWND hwnd) wchar_t temp[256]; temp[0] = 0; - GetClassNameW(hwnd, temp, sizeof(temp)); + GetClassNameW(hwnd, temp, sizeof(temp) / sizeof(wchar_t)); dstr_from_wcs(class, temp); }