bugGNU Octave - Bugs: bug #36778, Problem with matrix access in oct...

 
 

bug #36778: Problem with matrix access in oct files with versions > 3.4.3

Submitted by:  Sylvain Marchand <zygen>
Submitted on:  Tue 03 Jul 2012 04:01:48 PM UTC  
 
Category: InterpreterSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Other
Status: Works For MeAssigned to: None
Originator Name: Open/Closed: Closed
Release: 3.6.2Operating System: Mac OS

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

Wed 04 Sep 2013 03:54:25 PM UTC, comment #5:

No response for 2 months. Closing report.

Rik <rik5>
Project Administrator
Sat 22 Jun 2013 01:01:24 PM UTC, comment #4:

Can anyone with a OsS X version of Octave confirm that this bug still exists ?

D.

David Bateman <dbateman>
Project Member
Wed 04 Jul 2012 05:29:51 PM UTC, comment #3:

No, I don't have access to a system running OS X. If it is specific to OS X, then someone else will have to verify and debug this problem.

John W. Eaton <jwe>
Project Administrator
Wed 04 Jul 2012 05:24:04 PM UTC, comment #2:

Thank you very much for your time.

I have a MacOS 10.6.8 system, with octave from the fink distribution.

When I execute it, I get:

octave:1> inspect
Will be displayed...
ans = 0

i.e. the value is not displayed, and the second text line neither.
[as if the I/O were blocked]

Everything is fine with octave 3.4.3.
But with more recent versions, I get the incorrect execution.
I have tried both 32-bit and 64-bit compilation, and octave 3.6.0, 3.6.1, and 3.6.2. The problem is the same.
But maybe MacOS or fink specific?

Do you have access to a Mac version?

Thanks again.

Sylvain.

Sylvain Marchand <zygen>
Wed 04 Jul 2012 05:10:20 PM UTC, comment #1:

I don't understand what the problem is.

I don't see any errors from valgrind with 3.6.2 on my Debian system with this .oct file and it prints the following messages when I execute it:

John W. Eaton <jwe>
Project Administrator
Tue 03 Jul 2012 04:01:48 PM UTC, original submission:

Hello,

I encounter memory access problems with Matrix in oct files with octave versions > 3.4.3.

For example, the following code works with octave 3.4.3, but fails with octave 3.6.2.
[built with 'CXXFLAGS=-O2 mkoctfile inspect.cc' on MacOS 10.6.8]

Is this a bug or am I wrong (I have read the docs, the forums, and this code is quite simple...)?

Thanks in advance.

Best regards,

Sylvain.

--

#include <octave/oct.h>
#include <octave/parse.h>
#include <iostream>
#include <fstream>
#include <stdlib.h>
#include <string.h>

using namespace std;

DEFUN_DLD (inspect, args, , "inspect")
{
Matrix signal = Matrix (1,2);

signal(0) = 123.456;

cout << "Will be displayed..." << endl;

cout << signal(0) << endl;

cout << "Will NOT be displayed on recent Octave versions..." << endl;

return octave_value(0);
}

// End Of File

Sylvain Marchand <zygen>

 

(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 dbateman (Posted a comment)
  • -unavailable- added by jwe (Posted a comment)
  • -unavailable- added by zygen (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 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 04 Sep 2013 03:54:25 PM UTCrik5Open/ClosedOpen=>Closed
    Wed 04 Jul 2012 05:10:20 PM UTCjweStatusNone=>Works For Me

    Back to the top


    Powered by Savane 3.1-cleanup1