octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #45540] Segfault when moving the mouse over Qt


From: Dan Sebald
Subject: [Octave-bug-tracker] [bug #45540] Segfault when moving the mouse over Qt figures
Date: Sat, 25 Jul 2015 16:58:05 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:18.0) Gecko/20100101 Firefox/18.0 SeaMonkey/2.15

Follow-up Comment #11, bug #45540 (project octave):

Could the dynamic_cast be removed from this somehow?  (Looking around the
source tree just now my guess is the answer is "not easily".):


+      for (QList<graphics_object>::ConstIterator it = axesList.begin ();
+           it != axesList.end (); ++it)
+        {
+          const axes::properties& ap = 
+            dynamic_cast<const axes::properties&> ((*it).get_properties ());
+


That looks a little dodgy.  Or is this the generic way of handling graphics
objects?  Presumably if something is on the axesList it is in fact an axes
object and the cast is safe.  Another approach would be to use an iterator
that is an axes object rather than the more generic graphics object.  C++
constructs exist to avoid this kind of casting, but it seems a big change.

Well, going back to the original comment, it does appear that __init_fltk__
does do a lot of work with axes properties.  A grep for "axes::properties"
produces a mound of hits including:


grep "axes::properties" */*/*
[snip]
libinterp/dldfcn/__init_fltk__.cc:        axes::properties& ap =
libinterp/dldfcn/__init_fltk__.cc:         
dynamic_cast<axes::properties&>(ax_obj.get_properties ());
libinterp/dldfcn/__init_fltk__.cc:            axes::properties& ap =
libinterp/dldfcn/__init_fltk__.cc:             
dynamic_cast<axes::properties&>(go.get_properties ());
libinterp/dldfcn/__init_fltk__.cc:        axes::properties& ap =
libinterp/dldfcn/__init_fltk__.cc:          dynamic_cast<axes::properties&>
(ax.get_properties ());
libinterp/dldfcn/__init_fltk__.cc:        axes::properties& ap =
libinterp/dldfcn/__init_fltk__.cc:          dynamic_cast<axes::properties&>
(ax.get_properties ());
libinterp/dldfcn/__init_fltk__.cc:        axes::properties& ap =
libinterp/dldfcn/__init_fltk__.cc:          dynamic_cast<axes::properties&>
(ax.get_properties ());
libinterp/dldfcn/__init_fltk__.cc:                      axes::properties& ap
=
libinterp/dldfcn/__init_fltk__.cc:                       
dynamic_cast<axes::properties&>
libinterp/dldfcn/__init_fltk__.cc:                    axes::properties& ap =
libinterp/dldfcn/__init_fltk__.cc:                     
dynamic_cast<axes::properties&> (ax.get_properties ());
libinterp/dldfcn/__init_fltk__.cc:                          axes::properties&
ap = dynamic_cast<axes::properties&>


Also, the behavior from this patch changes slightly what is happening in
https://savannah.gnu.org/bugs/?45604 .  No longer does hovering over the dense
set of points produce the warning:


warning: opengl_selector::select: selection buffer overflow


That warning now only appears when I position the cursor above the pixels
where the dense data is and select using the left mouse button.  I will write
a note at that bug report and see if the patch fixes the crash problem for the
Windows user.  If not, there may still be an initialization issue.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?45540>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]