bugGNU Octave - Bugs: bug #52977, Octave can be caused to crash with...


bug #52977: Octave can be caused to crash with autoload'ed functions

Submitted by:  Olaf Till <i7tiol>
Submitted on:  Fri 26 Jan 2018 12:15:42 PM UTC  
Category:  Interpreter Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Segfault, Bus Error, etc.
Status:  Fixed Assigned to:  None
Originator Name:  Olaf Till Open/Closed:  Closed
Release:  dev Operating System:  GNU/Linux

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Wed 11 Apr 2018 04:44:55 AM UTC, comment #3:

Pushed to stable and merged to default:


John W. Eaton <jwe>
Project Administrator
Mon 09 Apr 2018 06:34:15 PM UTC, comment #2:

It would be really nice to have this small patch (https://savannah.gnu.org/support/download.php?file_id=43190) applied to 4.3.0+

Without it the parallel package compiles, but does not install.

With it the package does install (verified with 4.3.0+ hg_id 27fe7e6aba31+)

A.R. Burgers <arb>
Tue 06 Feb 2018 06:10:45 AM UTC, comment #1:

Same bug is triggered with

get_help_text ("somename")

if somename.oct is a file intended to be autoloaded with an alias.

This happens in installation of packages with such files, since Octaves builtin "__list_functions__" doesn't handle autoloads if called with a directory argument. (So that was triggers the bug is probably a bug itself. A different issue.)

The fix for the original bug (the segfault), enabling installation of such packages again, is checking if the loaded function is zero before using it. A small changeset is attached.

(file #43190)

Olaf Till <i7tiol>
Project Member
Fri 26 Jan 2018 12:15:42 PM UTC, original submission:

Octave version (development branch):
c241918d4c92, 2018-01-19 08:09:21 -0800

Octave can be caused to crash with autoload'ed functions.

The same (?) thing, with identical upper 2 frames of the backtrace,
happened to me in installation of a package with autoload'ed
functions, causing me to construct this procedure to reproduce
(hopefully the same) bug without package installation.


- for an arbitrary single DEFUN_DLD function "some_function" in file "test_interface.cc", build "test_interface.oct".
(for example this minimal function in file test_interface.cc:)
- from Octave commandline:
- from Octave commandline, call:
- from an external shell commandline:
- from Octave commandline, call a 2nd time:
-> crash

(Hint: In the test case, this possibly happened because with the alias 'autoload ("name_1", "name_2.oct")' the file was re-loaded after increasing modification time, while ordinarily (without an alias, and the file beeing named 'some_function.oct') only a warning is displayed:

rest of backtrace varies:

this was what I got in package installation:

and this is from with the described procedure to reproduce the bug:

Olaf Till <i7tiol>
Project Member


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

Attached Files
file #43190:  fix-52977.cset added by i7tiol (915B - application/octet-stream)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by arb (Posted a comment)
  • -email is unavailable- added by i7tiol (Submitted the item)

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.




    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-04-11 jwe StatusPatch Submitted => Fixed
        Open/ClosedOpen => Closed
    2018-02-06 i7tiol StatusNone => Patch Submitted
    2018-02-06 i7tiol Attached File- => Added fix-52977.cset, #43190

    Back to the top

    Powered by Savane 3.4