--with-blas/lapack being ignored
John W. Eaton
jwe at bevo.che.wisc.edu
Thu Dec 6 18:20:09 CST 2007
On 6-Dec-2007, Ben Abbott wrote:
| On Dec 6, 2007, at 6:34 PM, John W. Eaton wrote:
|
| > On 5-Dec-2007, Ben Abbott wrote:
| >
| > | Which may be duplicated with the simpler ....
| > |
| > | strptime ('09/13', '%m/%d')
| > | panic: Bus error -- stopping myself...
| > | attempting to save variables to `octave-core'...
| > | save to `octave-core' complete
| > | Bus error
| >
| > Does the attached program work correctly on your system?
| >
| > jwe
| >
| >
| > #define _XOPEN_SOURCE
| > #if defined (HAVE_SYS_TYPES_H)
| > #include <sys/types.h>
| > #if defined (HAVE_UNISTD_H)
| > #include <unistd.h>
| > #endif
| > #endif
| > #include <stdio.h>
| > #include <time.h>
| >
| > int
| > main (void)
| > {
| > struct tm t;
| > char *q = strptime ("09/13", "%m/%d", &t);
| > if (q)
| > {
| > printf ("%d/%d\n", t.tm_mon+1, t.tm_mday);
| > return 0;
| > }
| > else
| > return 1;
| > }
|
| gcc test.c
| ./a.out
| 9/13
|
| ... I assume that means the strptime is working?
It would seem so, and that should be precisely the call to strptime
that Octave is making when it crashes. You could verify this by
running Octave under the debugger and set a breakpoint in the
oct_strptime function and see what values are passed to the strptime
functoin and what it returns. But I suspect that may be working
correctly as your gdb trace showed that the crash is in
octave_base_tm::init, which is called after strptime.
If you set a breakpoint in octave_strptime::init and step through it
when you execute
strptime ('09/13', '%m/%d')
in Octave, what does oct_strptime return? Does it look like the
fields of the tm struct are set correctly? Does the tm struct contain
the tm_zone field? What is its value?
jwe
More information about the Bug-octave
mailing list