Issue with hggroup and zlim
Michael Goffioul
michael.goffioul at gmail.com
Thu Aug 28 14:35:38 CDT 2008
The only I see for this infinite recursion to occur is that an object
has himself as parent. The method base_properties::get_backend
should probably be made robust against such simple problem.
Michael.
On Thu, Aug 28, 2008 at 8:58 PM, John W. Eaton <jwe at bevo.che.wisc.edu> wrote:
> so the first call works, but the second fails. It appears to be an
> infinite recursion:
>
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 0x7ff7097956f0 (LWP 6479)]
> 0x00007ff7089ef780 in std::_Rb_tree<graphics_handle, std::pair<graphics_handle const, graphics_object>, std::_Select1st<std::pair<graphics_handle const, graphics_object> >, std::less<graphics_handle>, std::allocator<std::pair<graphics_handle const, graphics_object> > >::_M_lower_bound (this=Cannot access memory at address 0x7fff1115fff8
> )
> at /usr/include/c++/4.3/bits/stl_tree.h:954
> 954 const _Key& __k)
> Current language: auto; currently c++
> (gdb) where
> #0 0x00007ff7089ef780 in std::_Rb_tree<graphics_handle, std::pair<graphics_handle const, graphics_object>, std::_Select1st<std::pair<graphics_handle const, graphics_object> >, std::less<graphics_handle>, std::allocator<std::pair<graphics_handle const, graphics_object> > >::_M_lower_bound (this=Cannot access memory at address 0x7fff1115fff8
> )
> at /usr/include/c++/4.3/bits/stl_tree.h:954
> #1 0x00007ff7089ef829 in std::_Rb_tree<graphics_handle, std::pair<graphics_handle const, graphics_object>, std::_Select1st<std::pair<graphics_handle const, graphics_object> >, std::less<graphics_handle>, std::allocator<std::pair<graphics_handle const, graphics_object> > >::find (this=0x11361a0, __k=@0x7fff11160150)
> at /usr/include/c++/4.3/bits/stl_tree.h:1392
> #2 0x00007ff7089ef8a7 in std::map<graphics_handle, graphics_object, std::less<graphics_handle>, std::allocator<std::pair<graphics_handle const, graphics_object> > >::find (this=0x11361a0, __x=@0x7fff11160150)
> at /usr/include/c++/4.3/bits/stl_map.h:615
> #3 0x00007ff7089f0474 in gh_manager::do_get_object (this=0x11361a0,
> h=@0x7fff11160150) at ./graphics.h:8751
> #4 0x00007ff7089f0510 in gh_manager::get_object (h=@0x7fff11160150)
> at ./graphics.h:8575
> #5 0x00007ff708a6b78b in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1712
> #6 0x00007ff708b25329 in base_graphics_object::get_backend (this=0x1aad7b0)
> at ./graphics.h:2138
> #7 0x00007ff708b02509 in graphics_object::get_backend (this=0x7fff111601f0)
> at ./graphics.h:2303
> #8 0x00007ff708a6b7d9 in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1715
> #9 0x00007ff708b25329 in base_graphics_object::get_backend (this=0x1aad7b0)
> at ./graphics.h:2138
> #10 0x00007ff708b02509 in graphics_object::get_backend (this=0x7fff111602a0)
> at ./graphics.h:2303
> #11 0x00007ff708a6b7d9 in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1715
> #12 0x00007ff708b25329 in base_graphics_object::get_backend (this=0x1aad7b0)
> at ./graphics.h:2138
> #13 0x00007ff708b02509 in graphics_object::get_backend (this=0x7fff11160350)
> at ./graphics.h:2303
> #14 0x00007ff708a6b7d9 in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1715
> #15 0x00007ff708b25329 in base_graphics_object::get_backend (this=0x1aad7b0)
> at ./graphics.h:2138
> #16 0x00007ff708b02509 in graphics_object::get_backend (this=0x7fff11160400)
> at ./graphics.h:2303
> #17 0x00007ff708a6b7d9 in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1715
> #18 0x00007ff708b25329 in base_graphics_object::get_backend (this=0x1aad7b0)
> at ./graphics.h:2138
> #19 0x00007ff708b02509 in graphics_object::get_backend (this=0x7fff111604b0)
> at ./graphics.h:2303
> #20 0x00007ff708a6b7d9 in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1715
> #21 0x00007ff708b25329 in base_graphics_object::get_backend (this=0x1aad7b0)
> at ./graphics.h:2138
> #22 0x00007ff708b02509 in graphics_object::get_backend (this=0x7fff11160560)
> at ./graphics.h:2303
> #23 0x00007ff708a6b7d9 in base_properties::get_backend (this=0x1aad7c0)
> at /home/jwe/src/octave/src/graphics.cc:1715
>
> I have no clues at this point.
>
> jwe
>
>
> diff --git a/scripts/plot/__add_datasource__.m b/scripts/plot/__add_datasource__.m
> --- a/scripts/plot/__add_datasource__.m
> +++ b/scripts/plot/__add_datasource__.m
> @@ -32,20 +32,20 @@
> addproperty (strcat (data{i}, "datasource"), h, "string", "");
> endfor
>
> - i = 1;
> newargs = {};
> - while (i < numel (varargin))
> - arg = varargin{i++};
> - if (ischar (arg) && length (arg > 1) && strcmpi (arg(2:end), "datasource"))
> - arg = tolower (arg);
> - val = varargin{i++};
> +
> + for i = 1:2:numel (varargin)
> + key = varargin{i};
> + val = varargin{i+1};
> + if (length (key > 1) && strcmpi (key(2:end), "datasource"))
> if (ischar (val))
> - set (h, arg, val);
> + set (h, key, val);
> else
> - error ("%s: expecting data source to be a string", fcn);
> + error ("%s: expecting data source to be a string", fcn);
> endif
> else
> - newargs{end + 1} = arg;
> + newargs(end+1:end+2) = {key, val};
> endif
> - endwhile
> + endfor
> +
> endfunction
> diff --git a/scripts/plot/plot3.m b/scripts/plot/plot3.m
> --- a/scripts/plot/plot3.m
> +++ b/scripts/plot/plot3.m
> @@ -233,7 +233,7 @@
> "linestyle", options.linestyle,
> "marker", options.marker, "parent", hg, properties{:});
>
> - __add_line_series__ (h, hg);
> + __add_line_series__ (hline, hg);
>
> x = new;
> y_set = 0;
> @@ -303,7 +303,7 @@
> "linestyle", options.linestyle,
> "marker", options.marker, "parent", hg, properties{:});
>
> - __add_line_series__ (h, hg);
> + __add_line_series__ (hline, hg);
> endif
>
> set (gca (), "view", [-37.5, 30]);
>
> _______________________________________________
> Bug-octave mailing list
> Bug-octave at octave.org
> https://www-old.cae.wisc.edu/mailman/listinfo/bug-octave
>
>
More information about the Bug-octave
mailing list