Segfault with newest selection code.
On Mon, 17 Mar 2003, Andreas Schweitzer wrote:
PS: I'm working on a segfault due to the new selection code. Sebastian: I'll report itou as soon as I get to the point of isolating/defining the problem.
I encountered that one, too, I think. Hard to reproduce, though.
Here's how to reproduce it: Load the attached page from the location box, then focus the viewport by clicking past the end of the page. I guess that as there're no widgets in that space, the iterator code gets a NULL and from there comes the segfault. Cheers Jorge.-
On Mon, Mar 17, Jorge Arellano Cid wrote:
On Mon, 17 Mar 2003, Andreas Schweitzer wrote:
PS: I'm working on a segfault due to the new selection code. Sebastian: I'll report itou as soon as I get to the point of isolating/defining the problem.
I encountered that one, too, I think. Hard to reproduce, though.
Fixed. Jorge, thanks for the excellent bug report.
Here's how to reproduce it:
Load the attached page from the location box, then focus the viewport by clicking past the end of the page.
I guess that as there're no widgets in that space, the iterator code gets a NULL and from there comes the segfault.
No, the event is (since recently, for selections) sent to the toplevel widget, although its position is outside of the allocation of the latter. (If your assumtion would be correct, a_Selection_button_press would never be called :-) The problem is that the DwIterator, from which a DwExtIterator is constructed, points to a widget (the DwEmbedGtk containing the button), which is the last content in the page. a_Dw_ext_iterator_new tries to move forwards (since it must never point to a DW_CONTENT_WIDGET), and, of course, fails. Obviously, the fix is to move backwards then. Sebastian
participants (2)
-
Jorge Arellano Cid
-
Sebastian Geerken