Displaying 8 results from an estimated 8 matches for "rb_obj_is_kind_of".
2006 Sep 29
7
new crasher on bigdemo
Hi
Seems that the last round of commits makes bigdemo crash fairly quickly.
Guessing it''s something to do with either the Window or fixmodule change.
Program received signal EXC_BAD_ACCESS, Could not access memory.
0x00034fbc in rb_obj_is_kind_of (obj=3825080, c=1839676) at object.c:523
523 object.c: No such file or directory.
Any hints?
alex
2007 May 22
0
[1028] trunk/wxruby2/swig/classes/App.i: Fix some GC-mark crashes when SWIG trackings return an unexpected object
...mp;nbsp    // Check if it''s a descendant of Wx::Window, and if it has not yet been
-        // deleted by WxWidgets.
-        if ( rb_obj_is_kind_of(rb_obj, cWxWindow.klass) &&
</del><ins>+
+        // Check if it''s a valid object (sometimes SWIG doesn''t return what we''re
+      &nbs...
2007 Jul 20
0
[1125] trunk/wxruby2/swig/shared/control_with_items.i: Avoid MSW crashes when unexpected object is returned by SWIG tracking
...amp;nbsp // On Windows, sometimes the wrong object is associated with the
+        // ptr, so we check whether it is the right one to avoid crashes
+        if ( ! rb_obj_is_kind_of(rb_obj, cWxControlWithItems.klass) )
+         return;
+
</ins><span class="cx">         wxControlWithItems* wx_cwi = (wxControlWithItems*) ptr;
&l...
2007 Jul 21
0
[1133] trunk/wxruby2/swig/shared/control_with_items.i: Move mark func for ControlWithItems into shared file so changes affect
...amp;nbsp // On Windows, sometimes the wrong object is associated with the
-        // ptr, so we check whether it is the right one to avoid crashes
-        if ( ! rb_obj_is_kind_of(rb_obj, cWxControlWithItems.klass) )
-         return;
-
-        wxControlWithItems* wx_cwi = (wxControlWithItems*) ptr;
-     &...
2007 Jul 21
0
[1136] trunk/wxruby2/swig/classes/App.i: Note when the Wx::App is exiting and avoid doing GC if in process of
...p;nbsp       if ( TYPE(rb_obj) == T_DATA &&
</span><span class="cx">                  rb_obj_is_kind_of(rb_obj, cWxWindow.klass) &&
</span><del>-                 rb_iv_get(rb_obj, "@__wx_destroyed__") != Qtrue )
</del><ins>+&nbs...
2007 Jun 26
0
[1085] trunk/wxruby2/swig: Add checks and ruby exceptions for two common Wx::Window mistakes leading to
...mp;nbsp                      "Cannot create a Window before App.main_loop has been called");}
+ if ( ! $1 && ! rb_obj_is_kind_of(self, cWxTopLevelWindow.klass) )
+        { rb_raise(rb_eArgError,
+                  &...
2007 May 21
0
[1022] trunk/wxruby2/swig/classes/App.i: Memory mgmt: use Wx::App to mark still-alive Windows, set up Wx::THE_APP const
...mp;nbsp    // Check if it''s a descendant of Wx::Window, and if it has not yet been
+        // deleted by WxWidgets.
+        if ( rb_obj_is_kind_of(rb_obj, cWxWindow.klass) &&
+                 rb_iv_get(rb_obj, "@__wx_destroyed__") != Qtrue )
+      &...
2006 Dec 23
0
[794] trunk/wxruby2: Fix get_ruby_object so it works with SWIG tracking, move find_window_xx
...// Check the types match (see SWIG_NewPointerObj)
+         VALUE r_swigtype = rb_iv_get(r_obj, "__swigtype__");
+         if ( r_swigtype != Qnil && rb_obj_is_kind_of(r_obj, r_class) )
+                return r_obj;
</ins><span class="cx">         }
&l...