Emil Velikov (@xexaxo) commented about dlls/win32u/window.c:
if (win->dwExStyle & WS_EX_LAYOUTRTL) NtUserMirrorRgn( hwnd, shape );
NtGdiDeleteObjectApp( region );
- }
- if (get_window_region( hwnd, TRUE, ®ion, &visible )) goto done;
- if (!region) win->surface->funcs->set_region( win->surface, 0 );
if (!region) win->surface->funcs->set_region( win->surface, shape ); else { NtGdiOffsetRgn( region, -visible.left, -visible.top );
if (shape) NtGdiCombineRgn( region, region, shape, RGN_AND ); win->surface->funcs->set_region( win->surface, region ); NtGdiDeleteObjectApp( region );
}
if (shape) NtGdiDeleteObjectApp( shape );
Should probably move the DeleteObj after the done label. Otherwise it'll leak in the err path.