procmail
[Top] [All Lists]

SunOS memory faults from procmail -s

1997-11-09 16:31:23
I have the following shell script:

formail "${(_at_)}" -R 'From ' Old-From_: -a 'From ' -zYes procmail .${0##*/}

.${0##*/} is one of my links to my .procmailrc, which looks at $_ to know
how it's been invoked.  This problem occurs under the /bin/sh here and pdksh.
"$@" is almost always unset.  (It's there so that I can put in +number and
-number options for processing only part of a folder.)

Here is the uname -a output from the machine where it happens:

SunOS anago.wwa.com 5.6 Generic sun4u sparc SUNW,Ultra-2

When I feed the script a folder of email, it often bombs with a "Memory
Fault" message (or one of the shells here called it a "Segmentation Fault")
along the line, usually between messages but once in the middle of a message.
It never happens on single message input.  I have another formail (bunch of
header changing options) -dezcks call in another script, and has almost never
failed, but it just pipes the total output to another program instead of
invoking the other program for each extracted message as this script has to.

Now, here's the kicker; I can do this:

  formail -s name_of_script < input

with all the wasted calls to formail, and that *never* gives a memory fault
error and always finishes the job!

I know that the error messages are not coming from procmail because then
they'd go into $LOGFILE; these come on my screen.  They are clearly coming
from the shell because one shell gives a different message from the others,
and the error message strings always appear in the shell binaries, not in
formail's.

Short of the double formail call, does anyone have any advice?

<Prev in Thread] Current Thread [Next in Thread>
  • SunOS memory faults from procmail -s, David W. Tamkin <=