19 Aug
2024
19 Aug
'24
9:38 a.m.
Zhiyi Zhang (@zhiyi) commented about dlls/user32/edit.c:
+{ + RECT edit_rect; + int text_height = es->line_height * es->line_count; + + GetClientRect(es->hwndSelf, &edit_rect); + if (rc->bottom == 0 && rc->top == 0 && rc->right == 0 && rc->left == 0) + return 0; + if (rc->top >= rc->bottom) + return 0; + if (rc->left >= rc->right) + return 0; + if (text_height > (rc->bottom - rc->top)) + return 0; + if (es->text_width > (rc->right - rc->left)) + return 0; + if ((rc->bottom - rc->top) > (edit_rect.bottom - edit_rect.top)) Is this condition covered by your tests? What about (rc->right - rc->left) > (edit_rect.right - edit_rect.left)?
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/6304#note_79095