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

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

[Octave-bug-tracker] [bug #58004] (octave-forge) [io] xmlread.m makes Oc


From: Philip Nienhuis
Subject: [Octave-bug-tracker] [bug #58004] (octave-forge) [io] xmlread.m makes Octave crash
Date: Tue, 17 Mar 2020 10:13:53 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 6.1; rv:52.0) Gecko/20100101 Firefox/52.0

URL:
  <https://savannah.gnu.org/bugs/?58004>

                 Summary: (octave-forge) [io] xmlread.m makes Octave crash
                 Project: GNU Octave
            Submitted by: philipnienhuis
            Submitted on: Tue 17 Mar 2020 03:13:51 PM CET
                Category: Octave Forge Package
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Segfault, Bus Error, etc.
                  Status: None
             Assigned to: None
         Originator Name: Philip Nienhuis
        Originator Email: 
             Open/Closed: Open
                 Release: 6.0.90
         Discussion Lock: Any
        Operating System: GNU/Linux

    _______________________________________________________

Details:

During the release process of io-2.6.0 (still pending) we've hit hangs and
crashes related to xmlread.m.
See [*]

Steps to reproduce a crash (taken literally from Olaf's example in the
mentioned thread):

octave:2> hf = figure ();
octave:3> sombrero ();
octave:4> fname = [tempname(), ".svg"];
octave:5> print (fname);
octave:6> close (hf)

and loading the needed Java classes:

octave:8> javaaddpath ("/usr/share/java/xercesImpl.jar")
octave:9> javaaddpath ("/usr/share/java/xml-apis.jar")

, I got a segfault with repeatedly executing the further demo code:

octave:10> dom = xmlread (fname);
octave:11> dom.hasChildNodes ()
ans = 1
octave:12> root_node = dom.getChildNodes ().item (0);
octave:13> while (1)
> root_node = dom.getChildNodes ().item (0);
> endwhile
fatal: caught signal Segmentation fault -- stopping myself...
make: *** [Makefile:205: run] Segmentation fault


The xmlread.m code in itself looks correct (conforms to the Javadocs), and
trying the essential code parts in Matlab (r2014a) shows no errors and gives
correct output. Note that Matlab ships xercesImpl and xml-apis jars into its
installation. (I didn't try the while() in the example.)

Furthermore, the involved Java class libs xercesImpl.jar and xml-apis.jar are
very widely used (as is Java) so it seems almost inevitable to conclude that
the bug is in Octave itself.

FWIW, I've been unable to provoke the hangs or crashes on my Windows systems
(Windows 7 -to be retired very soon- and Windows 10) nor on my Mageia 7 Linux
systems, all with Octave-7.0.0 and Octave-6.0.0 from Feb. 17.

For the moment I plan to prepare an io package release w/o the xml functions,
they can be put back once this issue has been resolved.

Panxto (creator of the xml functions) cc'd

[*] https://sourceforge.net/p/octave/package-releases/405/





    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?58004>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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