[Top][All Lists]

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

Re: PSPP on windows: backtraces.

From: John Darrington
Subject: Re: PSPP on windows: backtraces.
Date: Wed, 21 Feb 2007 19:38:42 +0900
User-agent: Mutt/1.5.9i

On Sat, Feb 17, 2007 at 12:59:15PM +0900, John McCabe-Dansted wrote:
     Uh... if I compile with "-g -O0" only 15 tests fail, and I get no
     segfaults. I've put the log up at:

Can you try adding a "-b" to all the instances of "diff" in
tests/command/, tests/command/ and

I *think* this will fix these three failures.
     If this helps, I have put up a log with "-g -O2" at:

Many (all?) of the seg faults here have the form:

=>1 0x601b79dc memcpy+0x1c() in (0x0099fc28)
  2 0x00458769 dfm_put_record+0xc9(w=0x126e10, rec=0x12e500, len=0x4)
 in pspp (0x0099fc58)
So it looks as if there may be a problem with dfm_put_record.
Examining that function, I'm suspicious, because:

 switch (fh_get_mode (w->fh))
    case FH_MODE_TEXT:
      fwrite (rec, len, 1, w->file);
      putc ('\n', w->file);

    case FH_MODE_BINARY:
        size_t record_width = fh_get_record_width (w->fh);
        size_t write_bytes = MIN (len, record_width);
        size_t pad_bytes = record_width - write_bytes;
        fwrite (rec, write_bytes, 1, w->file);

... the tests for record_width are not performed in the first case.
And this case I suspect never arises except under windows.  I suggest
that we start by putting some assertions in the first case of this
switch  and see what happens.


PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See or any PGP keyserver for public key.

Attachment: signature.asc
Description: Digital signature

reply via email to

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