octave-maintainers
[Top][All Lists]
Advanced

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

Re: GUI crash exit 11 again


From: Daniel J Sebald
Subject: Re: GUI crash exit 11 again
Date: Sat, 05 Jul 2014 01:24:34 -0500
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111108 Fedora/3.1.16-1.fc14 Thunderbird/3.1.16

On 07/04/2014 08:02 PM, Jordi Gutiérrez Hermoso wrote:
On Fri, 2014-07-04 at 14:26 -0700, martine1212 wrote:
I am not really a programmer.... but I will do my best to find what is
causing it.

The only thing that can help obtain a diagnosis is a stack trace in
gdb. Everything else is guesswork and voodoo.

- Jordi G. H.

Come on Jordi, give us more credit than just mystical guesswork.

This one may not be Octave's bug, but we should double check this to verify the GNU library is being used correctly.

I looked at libinterp/octave.cc for the use of "force-gui". The variable force_gui_option is used in such a straightforward way and is isolated to the file octave.cc that I can't imagine the bug resides after the point of checking if the GUI needs to be launched.

So I'm guessing the problem is somewhere prior and that some memory in program space is being corrupted due to use of a bad pointer. I'm thinking it could be this line:

int optc = getopt_long (argc, argv, short_opts, long_opts, &long_idx);

in libinterp/octave.cc. getopt_long looks to be something from the GNU library. See file libgnu/getopt.h for the complex set of definitions concerning getopt_long.

There are several things that could be happening.

1) Octave is using getopt_long from a library which is bad on martine1212's system. [Would be my guess seeing as though others with similar setups aren't seeing this bug.]

2) Octave is not using getopt_long() function properly in terms of input arguments. [But I've checked the code and to me it looks like Octave is using the function in a valid way.]

3) Somehow the definitions in getopt.h are pre-processing out the declaration for getopt_long() and the compiler is build a bad function interface.

martine1212, could you please "touch libinterp/octave.cc" from the root source directory and then make octave? Look for any warnings that might appear for "getopt_long" during the build process.

I have two the same machine at work..running Suse 12.3.... one does not
crash the other one crashes.

Is there some way that you can check the version of GNU library on both of these systems? I'm not seeing anything in config.h about the GNULIB version, just stuff like:

#define GNULIB_TEST_GETOPT_GNU 1

If you are adventurous, change the line of code

int optc = getopt_long (argc, argv, short_opts, long_opts, &long_idx);

so that it looks like the following three lines:

// int optc = getopt_long (argc, argv, short_opts, long_opts, &long_idx);
force_gui_option = true;
optc = -1;

(All that does is bypass the getopt_long() call and configure things as though "--force-gui" was the only option.) Recompile and run "octave --force-gui" once again to see if the program crashes or not.

Dan



reply via email to

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