[26187] in Perl-Users-Digest
Perl-Users Digest, Issue: 8376 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Aug 31 21:05:30 2005
Date: Wed, 31 Aug 2005 18:05:04 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Wed, 31 Aug 2005 Volume: 10 Number: 8376
Today's topics:
Re: array question (newbie) <john@castleamber.com>
Re: array question (newbie) <1usa@llenroc.ude.invalid>
Re: Dealing With Zombies in a Daemon <dwilga-MUNGE@mtholyoke.edu>
Re: how to add a space using a regex <matthew.garrish@sympatico.ca>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: 31 Aug 2005 18:23:10 GMT
From: John Bokma <john@castleamber.com>
Subject: Re: array question (newbie)
Message-Id: <Xns96C38803D3FB0castleamber@130.133.1.4>
"A. Sinan Unur" <1usa@llenroc.ude.invalid> wrote:
> John Bokma <john@castleamber.com> wrote in
> news:Xns96C2F158BB4CFcastleamber@130.133.1.4:
>
>> "A. Sinan Unur" <1usa@llenroc.ude.invalid> wrote:
>>
>>> You don't have warnings enabled. Have you read the posting
guidelines
>>> for this group yet?
>>
>> I was just wondering, if postings that don't follow the posting
>> guidelines are just ignored, especially by the regulars *and*
together
>> with the FAQ xx.yy (or maybe instead of) a message is posted:
>>
>> Subject: Why is your message not answered?
>>
>> With a link to posting guidelines
>> (and to the FAQ)?
>
> Even if we ignore messages, I am sure someone will reply.
Most replies are by regulars which write the same over and over again
(use strict, etc.). I am sure most of them can be convinced to stop
replying.
> If, say the OP
> in this thread, had to choose between reading a separate "Why is your
> message not answered?" thread as opposed to those replies, I have a
> feeling they'll choose the response, and ignore the pointers.
Most even ignore the response as well, as you probably must have noticed
on many occassions. If most regulars stop replying to posts that don't
follow the posting guidelines, or are not about Perl, a lot of noise
might be gone.
I am going to try it :-D.
--
John Small Perl scripts: http://johnbokma.com/perl/
Perl programmer available: http://castleamber.com/
Happy Customers: http://castleamber.com/testimonials.html
------------------------------
Date: Wed, 31 Aug 2005 18:28:52 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: array question (newbie)
Message-Id: <Xns96C3934F6249Basu1cornelledu@127.0.0.1>
John Bokma <john@castleamber.com> wrote in
news:Xns96C38803D3FB0castleamber@130.133.1.4:
> If most regulars stop replying to posts that don't follow
> the posting guidelines, or are not about Perl, a lot of
> noise might be gone.
I agree it is worth a shot.
> I am going to try it :-D.
I'll try to follow your lead.
Sinan
--
A. Sinan Unur <1usa@llenroc.ude.invalid>
(reverse each component and remove .invalid for email address)
comp.lang.perl.misc guidelines on the WWW:
http://mail.augustmail.com/~tadmc/clpmisc/clpmisc_guidelines.html
------------------------------
Date: Wed, 31 Aug 2005 12:10:50 -0400
From: Dan Wilga <dwilga-MUNGE@mtholyoke.edu>
Subject: Re: Dealing With Zombies in a Daemon
Message-Id: <dwilga-MUNGE-0330FD.12105031082005@nap.mtholyoke.edu>
In article <HJGdnYDVYcVVP47eRVn-oQ@comcast.com>,
Hal Vaughan <hal@thresholddigital.com> wrote:
> 1) Do the unreaped zombies actually take up memory space, or just a number
> in the list of PIDs?
Both. The worst part is that most operating systems have a limit on the
number of processes that is lower than the range of possible PIDs. When
you hit this limit, weird things start to happen, because all of the
various daemons can no longer fork.
> 2) I understand I can reap by setting $SIG{CHLD} to IGNORE, is that by just
> using an assignment ($SIG{CHLD} = IGNORE), and how well does it work? The
> name makes me think it just ignores zombies without doing anything.
That's exactly what it does. Technically, it ignores children that
terminate. They never have time to become zombies.
> 3) Am I doing something wrong in the routines below, or is there a better
> way to do this?
Instead of cleaning up at set intervals, why not just do it in the
$SIG{CHLD} handler?
$SIG{CHLD} = \&reaper;
...
sub reaper {
1 while( ($waitedpid = waitpid( -1, WNOHANG )) > 0 );
$SIG{CHLD} = \&reaper; # apparently needed on some OSes
}
> 4) Why is the program hanging and waiting for the program that is still
> running?
That, I'm not so sure about. It could be because your OS is one that
requires the signal handler to be reset in %SIG every time the signal is
caught. My example shows this, as does `perldoc perlipc`.
--
Dan Wilga dwilga-MUNGE@mtholyoke.edu
** Remove the -MUNGE in my address to reply **
------------------------------
Date: Wed, 31 Aug 2005 19:05:27 -0400
From: "Matt Garrish" <matthew.garrish@sympatico.ca>
Subject: Re: how to add a space using a regex
Message-Id: <RIqRe.4376$884.624586@news20.bellglobal.com>
"Bernard El-Hagin" <bernard.el-haginDODGE_THIS@lido-tech.net> wrote in
message news:Xns96C39C786F50Felhber1lidotechnet@62.89.127.66...
> "Matt Garrish" <matthew.garrish@sympatico.ca> wrote:
>
> [...]
>
>>> I suggest that two letter first names are quite rare, which leads
>>> to an obvious adjustment of your regex. Still not perfect, but
>>> much closer.
>>>
>>
>> Discounting Asian surnames, which are often two letters and
>> precede the proper name...
>
>
> Yes, and what about "El-Hagin"? That's gotta be annoying.
>
>
>> And how about all the Eds and Als in the world?
>
>
> What about them?
>
Well, Ed was saying to Al that he was amazed so many people waste letters...
oh never mind. : )
Matt
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc. For subscription or unsubscription requests, send
#the single line:
#
# subscribe perl-users
#or:
# unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V10 Issue 8376
***************************************