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

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

[Octave-bug-tracker] [bug #50189] Segfault when drawing sphere as first


From: Rik
Subject: [Octave-bug-tracker] [bug #50189] Segfault when drawing sphere as first plot
Date: Wed, 1 Feb 2017 20:17:53 +0000 (UTC)
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0

Follow-up Comment #12, bug #50189 (project octave):

I still can't reproduce this using


newplot; newplot


but clearly I am in the minority.

If the problem is with allchild, does this quick fix work?


diff -r 35e3d199527c scripts/plot/util/newplot.m
--- a/scripts/plot/util/newplot.m       Tue Jan 31 17:29:32 2017 -0800
+++ b/scripts/plot/util/newplot.m       Wed Feb 01 12:16:16 2017 -0800
@@ -198,7 +198,10 @@ function hax = newplot (hsave = [])
           delete (ca);
           ca = axes ();
         elseif (do_reset)
-          delete (allchild (ca));
+          ht = [get(ca, {"xlabel", "ylabel", "zlabel", "title"}){:}];
+          ac = allchild (ca);
+          hdel = setdiff (ac, ht);
+          delete (hdel);
           reset (ca);
         endif
       endif


The diff is attached as well if you want to download for testing.


(file #39642)
    _______________________________________________________

Additional Item Attachment:

File name: newplot.diff                   Size:0 KB


    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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