http://bugs.winehq.org/show_bug.cgi?id=10439
Alex Villacís Lasso a_villacis@palosanto.com changed:
What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|wine-bugs@winehq.org |a_villacis@palosanto.com Status|NEW |ASSIGNED
--- Comment #3 from Alex Villacís Lasso a_villacis@palosanto.com 2007-12-07 23:25:16 --- Created an attachment (id=9545) --> (http://bugs.winehq.org/attachment.cgi?id=9545) Invalidate all the text on bogus last selection
When removing text, beginning and end offsets of last selection are not inmediately updated. When calling ME_InvalidateSelection() in paint.c, the values are clipped to the current length of the text. However, even after clipping, the values are unusable for deciding which parts of the text should be updated. The control can very well try to mark invalidated paragraphs past the end of the last paragraph, triggering a null pointer access. The application RadDecay at bug #10439 crashes because of this.
The attached patch just ignores the values when one or both of them point past the length of the current text, and invalidates everything. Existing code then recalculates the new selection beginning and end anew.
Patch already sent to wine-patches.