bugGNU Octave - Bugs: bug #46926, saveas() crashes Octave

 
 

bug #46926: saveas() crashes Octave

Submitted by:  None
Submitted on:  Mon 18 Jan 2016 08:14:04 AM UTC  
 
Category: Plotting with OpenGLSeverity: 4 - Important
Priority: 5 - NormalItem Group: Segfault, Bus Error, etc.
Status: FixedAssigned to: None
Originator Name: Christian RidderströmOriginator Email: -unavailable-
Open/Closed: ClosedRelease: 4.0.0
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.

 

(Jump to the original submission Jump to the original submission)

Mon 08 Aug 2016 01:37:52 AM UTC, comment #7:

Assuming fix in cset ae4d7dfea337 works since there was no follow up. Closing report.

Rik <rik5>
Project Administrator
Fri 08 Apr 2016 08:16:14 PM UTC, comment #6:

Can you build from Mercurial sources? It is very likely that this has been fixed with anything newer than cset ae4d7dfea337 (4/1/16).

Rik <rik5>
Project Administrator
Wed 02 Mar 2016 01:04:20 AM UTC, comment #5:

Thanks, Christian. You can normally get a stack trace by running

and typing "run" at the gdb prompt.

Lachlan Andrew <lachlan>
Project Member
Tue 01 Mar 2016 02:27:29 PM UTC, comment #4:

Sorry, did not have an e-mail address assocated here so didn't get a notice on your responses.

Regarding pausing, Octave crashes also if I do e.g.:

>> figure(1); plot(1,1,'.');
>> saveas(1, 'test.png');


Not sure how to provide a stack trace, but tried starting Octave with
octave --no-gui --debug
This gives me a lot of output... below I'm pasting in only the last few lines.

I also tried 'stracte octave --no-gui', but that output didn't seem so useful. I could attach it though.
/Christian

Entering state 189
Next token is token END_OF_INPUT ()
Shifting token END_OF_INPUT ()
Entering state 291
Reducing stack by rule 195 (line 1403):
$1 = token INPUT_FILE ()
$2 = nterm opt_nl ()
$3 = nterm opt_list ()
$4 = token END_OF_INPUT ()
-> $$ = nterm file ()
Stack now 0
Entering state 66
Reducing stack by rule 141 (line 944):
$1 = nterm file ()
-> $$ = nterm command ()
Stack now 0
Entering state 57
Reducing stack by rule 14 (line 453):
$1 = nterm command ()
-> $$ = nterm statement ()
Stack now 0
Entering state 38
Reducing stack by rule 6 (line 429):
$1 = nterm statement ()
-> $$ = nterm simple_list1 ()
Stack now 0
Entering state 37
Return for a new token:
Reading a token: Next token is token END_OF_INPUT ()
Reducing stack by rule 268 (line 1969):
-> $$ = nterm opt_sep_no_nl ()
Stack now 0 37
Entering state 114
Reducing stack by rule 5 (line 425):
$1 = nterm simple_list1 ()
$2 = nterm opt_sep_no_nl ()
-> $$ = nterm simple_list ()
Stack now 0
Entering state 36
Next token is token END_OF_INPUT ()
Shifting token END_OF_INPUT ()
Entering state 111
Reducing stack by rule 2 (line 405):
$1 = nterm simple_list ()
$2 = token END_OF_INPUT ()
Stack now 0
panic: Segmentation fault -- stopping myself...
attempting to save variables to 'octave-workspace'...
save to 'octave-workspace' complete
Segmentation fault (core dumped)

Anonymous
Wed 20 Jan 2016 05:56:37 PM UTC, comment #3:

Mike, the bug I was thinking of is bug #46447. It turns out I hadn't submitted the patch, but have now. Looking closer, the patch may not solve the problem since the original plot didn't fail.

Lachlan Andrew <lachlan>
Project Member
Wed 20 Jan 2016 07:35:54 AM UTC, comment #2:

Mike, my guess would be that it is a missing font, given the absence of several binaries. That is a known bug, that I have submitted a patch for. I'll dig it up and get back to you.

Lachlan Andrew <lachlan>
Project Member
Mon 18 Jan 2016 06:50:10 PM UTC, comment #1:

Thanks for your bug report. The epstool error is not related to the crash, it's more likely to be a timing or graphics driver related problem. The crash does not occur for me with your provided example.

Can you try your example with a pause between the peaks() and saveas() calls (just wait at the prompt for a couple seconds) and see if that works differently?

If the crash always occurs regardless of pausing or not, can you provide a gdb stacktrace?

Mike Miller <mtmiller>
Project Administrator
Mon 18 Jan 2016 08:14:04 AM UTC, original submission:

Hi,

When trying to save a figure in format 'png', Octave crashes.
This is from an almost clean installation of Ubuntu 15.10.
Octave crashes both when ran with GUI and without.
Below is a very short sequence that crashes Octave for me.
In essence it's:
fig=figure(1); peaks(); saveas(fig, 'test.png', 'png')

I suppose it'd be ok that saving as PNG doesn't work because some tools are missing, but it shouldn't crash Octave in my opinion.

Regards,
Christian

$ octave --no-gui
GNU Octave, version 4.0.0
Copyright (C) 2015 John W. Eaton and others.
This is free software; see the source code for copying conditions.
There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. For details, type 'warranty'.

Octave was configured for "x86_64-pc-linux-gnu".

Additional information about Octave is available at http://www.octave.org.

Please contribute if you find this software useful.
For more information, visit http://www.octave.org/get-involved.html

Read http://www.octave.org/bugs.html to learn how to submit bug reports.
For information about changes from previous versions, type 'news'.

>> fig=figure(1); peaks(); saveas(fig, 'test.png', 'png')

warning: print.m: epstool binary is not available.
Some output formats are not available.
warning: called from
_print_parse_opts_ at line 382 column 9
print at line 291 column 8
saveas at line 105 column 3
warning: print.m: fig2dev binary is not available.
Some output formats are not available.
panic: Segmentation fault -- stopping myself...
attempting to save variables to 'octave-workspace'...
save to 'octave-workspace' complete
Segmentation fault (core dumped)

Anonymous

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by lachlan (Posted a comment)
  • -unavailable- added by mtmiller (Posted a comment)
  • -unavailable- added by None (Submitted the item)
  •  

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

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 08 Aug 2016 01:37:52 AM UTCrik5StatusNeed Info=>Fixed
      Open/ClosedOpen=>Closed
    Fri 01 Jul 2016 05:27:25 PM UTCrik5Severity3 - Normal=>4 - Important
    Mon 18 Jan 2016 06:50:10 PM UTCmtmillerCategoryPlotting=>Plotting with OpenGL
      StatusNone=>Need Info

    Back to the top


    Powered by Savane 3.1-cleanup1