Thread: Problem in SAC using sac macro

Started: 2007-08-15 09:07:09
Last activity: 2007-08-16 05:52:40
Topics: SAC Help
Sudhir Rajaure
2007-08-15 09:07:09
Dear Sir/Madam

I couldn't use the following macro to prepare waveforms for inversion in the
search of fault plane solution.

r %base%BHZ* %base%BHE* %base%BHN*

SAC exist with message "segmentation fault"

I think this problem arouse on account of small value of RAM (128 MB). Could
you please write the real cause and how to fix it?



From: sac-help-request<at>
Reply-To: sac-help<at>
To: sac-help<at>
Subject: sac-help Digest, Vol 26, Issue 2
Date: Fri, 3 Aug 2007 12:01:48 -0700 (PDT)

Send sac-help mailing list submissions to

To subscribe or unsubscribe via the World Wide Web, visit
or, via email, send a message with subject or body 'help' to

You can reach the person managing the list at

When replying, please edit your Subject line so it is more specific
than "Re: Contents of sac-help digest..."

Today's Topics:

1. Bug Report rsac1/rsac2 in sacio (Brian Savage)


Message: 1
Date: Fri, 3 Aug 2007 10:40:37 -0400
From: Brian Savage <savage<at>>
Subject: [SAC-HELP] Bug Report rsac1/rsac2 in sacio
To: SAC HELP <sac-help<at>>
Message-ID: <9617BFAB-73A0-4C83-B906-184FDBBC9EA2<at>>
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed

SAC Users

A bug had been discovered when using rsac1() from the sacio library.
This bug also affects rsac2() as the function logic is essentially
the same.

If the sac file being read contains more data points than expected an
error value is not returned as it should be. A error return value
(variable nerr) of -803 should be returned but is this value is set
to 0 if no other errors are encountered. The number of data points
read in (variable nlen) will be returned and set to the maximum
number allowed (variable max).

If the number of data points rsac1 (or rsac2) returns as read
(variable nlen) is equal to the maximum number allowed (variable max)
there is a possibility that the requested file to be read contains
more points. Increase the size of the array and reread the file.

Fix: (Either 1 or 2)
1) This bug will be fixed in the next release of SAC
2) Request an updated rsac1() and rsac2() and recompile the sacio
library from source.

Brian Savage


sac-help mailing list

End of sac-help Digest, Vol 26, Issue 2

Tease your brain--play Clink! Win cool prizes!

  • andreas wessel
    2007-08-16 05:52:40
    There are several things that cause this error message.

    Maybe your data has the wrong endianness? This is not a problem in the
    current version of SAC, but it was an issue in "veteran" versions.
    Which one are you using?


    On 8/15/07, Sudhir Rajaure <srajaure<at>> wrote:

    r %base%BHZ* %base%BHE* %base%BHN*

    SAC exist with message "segmentation fault"

06:24:01 v.ad6b513c