[13791] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 1201 Volume: 9

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Oct 27 23:33:01 1999

Date: Wed, 27 Oct 1999 20:32:37 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <941081557-v9-i1201@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Wed, 27 Oct 1999     Volume: 9 Number: 1201

Today's topics:
        Submit button thwarted by Reload <aneely@softouch.on.ca>
    Re: Submit button thwarted by Reload <aneely@softouch.on.ca>
    Re: Submit button thwarted by Reload <aneely@softouch.on.ca>
    Re: Submit button thwarted by Reload <damon@nic.cc>
    Re: Submit button thwarted by Reload <flavell@mail.cern.ch>
    Re: Submit button thwarted by Reload <flavell@mail.cern.ch>
    Re: Submit button thwarted by Reload <rootbeer@redcat.com>
        subroutines in regular expressions <mel@disc.com>
    Re: subroutines in regular expressions (Tad McClellan)
    Re: subroutines in regular expressions <lr@hpl.hp.com>
        Surely my pain is worth something ... (Mitchell Morris)
        Sv: Make Dir. <ssf@fallesen-internet.dk>
    Re: Sv: Make Dir. (Michel Dalle)
        sysread / syswrite ? <howitgolook@my-deja.com>
    Re: sysread / syswrite ? <cassell@mail.cor.epa.gov>
        system() call hangs, child is defunct <sn192he@uni-duisburg.de>
    Re: system() call hangs, child is defunct <rootbeer@redcat.com>
    Re: system() call hangs, child is defunct (M.J.T. Guy)
    Re: system() call hangs, child is defunct <sn192he@uni-duisburg.de>
    Re: system() call hangs, child is defunct <bernie@fantasyfarm.com>
    Re: system() call hangs, child is defunct <rootbeer@redcat.com>
        test <oneillNOonSPAM@cs.uregina.ca.invalid>
    Re: Text::Template and -T <rootbeer@redcat.com>
        Thesaurus Module/Data? damon@nic.cc
    Re: Thesaurus Module/Data? <2bunnyhop@home.com>
    Re: this darn error (Abigail)
        Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Mon, 25 Oct 1999 17:32:04 -0400
From: Amer Neely <aneely@softouch.on.ca>
Subject: Submit button thwarted by Reload
Message-Id: <3814CC54.4100B80@softouch.on.ca>

I have a very simple message-board script which takes input from a form
and upon submit, calls itself. It writes the information to a file, and
then checks to see if any new files have been added (which contain the
contents of previous postings), and displays them.

My problem is that a new user may be tempted to hit the "Reload" or
"Refresh" button of their browser to see if any new postings have
appeared. This results in the popup window inquiring whether to "repost
from data?". Users may tend to press the "OK" button, which of course,
has the unfortunate side effect of reposting the data. This in turn
creates a new file, which in turn gets read and displayed. 

End result is potentially multiple postings.

Is there a way to flush the browser memory or somehow negate this
action?
-- 
Amer Neely aneely@softouch.on.ca
Certified Internet Webmaster Designer
Softouch Information Services: http://www.softouch.on.ca/
Research Central: http://www.softouch.on.ca/rc/
Member: HTML Writers Guild: http://www.hwg.org/
Member: Association of Web Professionals: http://www.a-w-p.org/


------------------------------

Date: Mon, 25 Oct 1999 22:39:07 -0400
From: Amer Neely <aneely@softouch.on.ca>
To: Damon Miller <damon@nic.cc>
Subject: Re: Submit button thwarted by Reload
Message-Id: <3815144B.7316ABE7@softouch.on.ca>

Damon Miller wrote:
> 
> I'd post the message then send the browser a location header ("Location:
> http://.../myscript.cgi?action=menu"), so that when they reload they're
> reloading the menu query and not the post-message query.
> 
> I'd also consider posting this message to the cgi newgroup rather than
> here, if you don't want to get flamed by some of the more puritanical and
> outspoken members of this group.
> 
> -Damon

Yowch. I should know better - I'm in Perl-mode. I will try your
suggestion though - thanks.
> 
> Amer Neely wrote:
> 
> > I have a very simple message-board script which takes input from a form
> > and upon submit, calls itself. It writes the information to a file, and
> > then checks to see if any new files have been added (which contain the
> > contents of previous postings), and displays them.
> >
> > My problem is that a new user may be tempted to hit the "Reload" or
> > "Refresh" button of their browser to see if any new postings have
> > appeared. This results in the popup window inquiring whether to "repost
> > from data?". Users may tend to press the "OK" button, which of course,
> > has the unfortunate side effect of reposting the data. This in turn
> > creates a new file, which in turn gets read and displayed.
> >
> > End result is potentially multiple postings.
> >
> > Is there a way to flush the browser memory or somehow negate this
> > action?

-- 
Amer Neely aneely@softouch.on.ca
Certified Internet Webmaster Designer
Softouch Information Services: http://www.softouch.on.ca/
Research Central: http://www.softouch.on.ca/rc/
Member: HTML Writers Guild: http://www.hwg.org/
Member: Association of Web Professionals: http://www.a-w-p.org/


------------------------------

Date: Mon, 25 Oct 1999 22:41:37 -0400
From: Amer Neely <aneely@softouch.on.ca>
Subject: Re: Submit button thwarted by Reload
Message-Id: <381514E1.6526EABB@softouch.on.ca>

"Alan J. Flavell" wrote:
> 
> On Mon, 25 Oct 1999, Amer Neely wrote:
> 
> > from data?". Users may tend to press the "OK" button, which of course,
> > has the unfortunate side effect of reposting the data. This in turn
> > creates a new file, which in turn gets read and displayed.
> 
> This is only one of the many ways of inadvertently creating multiple
> submissions.  Fact of life in CGI-land, and discussed in any reasonable
> CGI script tutorial.  Probably even an FAQ.
> 
> There's a usenet group dedicated to CGI, you know.  The Perl FAQs
> helpfully have a section dealing with CGI issues, but don't let that
> mislead you into believing that designing a CGI script is a Perl
> language question.
>

Fer sure. I'm in Perl-mode, thus my posting here. But I should know
better. Thanks.

-- 
Amer Neely aneely@softouch.on.ca
Certified Internet Webmaster Designer
Softouch Information Services: http://www.softouch.on.ca/
Research Central: http://www.softouch.on.ca/rc/
Member: HTML Writers Guild: http://www.hwg.org/
Member: Association of Web Professionals: http://www.a-w-p.org/


------------------------------

Date: Mon, 25 Oct 1999 15:24:48 -0700
From: Damon Miller <damon@nic.cc>
Subject: Re: Submit button thwarted by Reload
Message-Id: <3814D8AF.D8CAC808@nic.cc>

This is a multi-part message in MIME format.
--------------5E6691A0575665F14744261B
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

I'd post the message then send the browser a location header ("Location:
http://.../myscript.cgi?action=menu"), so that when they reload they're
reloading the menu query and not the post-message query.

I'd also consider posting this message to the cgi newgroup rather than
here, if you don't want to get flamed by some of the more puritanical and
outspoken members of this group.

-Damon

Amer Neely wrote:

> I have a very simple message-board script which takes input from a form
> and upon submit, calls itself. It writes the information to a file, and
> then checks to see if any new files have been added (which contain the
> contents of previous postings), and displays them.
>
> My problem is that a new user may be tempted to hit the "Reload" or
> "Refresh" button of their browser to see if any new postings have
> appeared. This results in the popup window inquiring whether to "repost
> from data?". Users may tend to press the "OK" button, which of course,
> has the unfortunate side effect of reposting the data. This in turn
> creates a new file, which in turn gets read and displayed.
>
> End result is potentially multiple postings.
>
> Is there a way to flush the browser memory or somehow negate this
> action?
> --
> Amer Neely aneely@softouch.on.ca
> Certified Internet Webmaster Designer
> Softouch Information Services: http://www.softouch.on.ca/
> Research Central: http://www.softouch.on.ca/rc/
> Member: HTML Writers Guild: http://www.hwg.org/
> Member: Association of Web Professionals: http://www.a-w-p.org/

--------------5E6691A0575665F14744261B
Content-Type: text/x-vcard; charset=us-ascii;
 name="damon.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Damon Miller
Content-Disposition: attachment;
 filename="damon.vcf"

begin:vcard 
n:Miller;Damon
tel;work:206.381.0402
x-mozilla-html:FALSE
adr:;;;;;;
version:2.1
email;internet:damon@nic.cc
fn:Damon Miller
end:vcard

--------------5E6691A0575665F14744261B--



------------------------------

Date: Tue, 26 Oct 1999 01:58:27 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: Submit button thwarted by Reload
Message-Id: <Pine.HPP.3.95a.991026015334.10748A-100000@hpplus01.cern.ch>

On Mon, 25 Oct 1999, Amer Neely wrote:

> from data?". Users may tend to press the "OK" button, which of course,
> has the unfortunate side effect of reposting the data. This in turn
> creates a new file, which in turn gets read and displayed. 

This is only one of the many ways of inadvertently creating multiple
submissions.  Fact of life in CGI-land, and discussed in any reasonable
CGI script tutorial.  Probably even an FAQ.

There's a usenet group dedicated to CGI, you know.  The Perl FAQs
helpfully have a section dealing with CGI issues, but don't let that
mislead you into believing that designing a CGI script is a Perl
language question.

> Is there a way to flush the browser memory

Probably the wrong approach.  If your script has been designed to
protect against multiple submissions, it'll protect against this one
too. 




------------------------------

Date: Tue, 26 Oct 1999 02:10:03 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: Submit button thwarted by Reload
Message-Id: <Pine.HPP.3.95a.991026020432.10748C-100000@hpplus01.cern.ch>


On Mon, 25 Oct 1999, Damon Miller exposed himself to the assembled
usenauts by causing this to appear:

 Parts/attachments:
    1 Shown   35 lines  Text
    2   OK     9 lines  Text, "Card for Damon Miller"
 ----------------------------------------

and then opined:

> I'd also consider posting this message to the cgi newgroup rather than
> here, if you don't want to get flamed by some of the more puritanical and
> outspoken members of this group.

And set the finishing touch with a comprehensive jeopardendum before
disappearing up his own...


Thanks for helping me understand that I was right, and you are a
pestilential troll.  



------------------------------

Date: Mon, 25 Oct 1999 15:41:43 -0700
From: Tom Phoenix <rootbeer@redcat.com>
Subject: Re: Submit button thwarted by Reload
Message-Id: <Pine.GSO.4.10.9910251540590.29843-100000@user2.teleport.com>

On Mon, 25 Oct 1999, Amer Neely wrote:

> Is there a way to flush the browser memory or somehow negate this
> action?

It sounds as if you want to ask a browser to do something. Perhaps you
should search for the docs, FAQs, and newsgroups about protocols used to
talk to browsers. Cheers!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



------------------------------

Date: Tue, 26 Oct 1999 18:08:04 GMT
From: Mark Lofdahl <mel@disc.com>
Subject: subroutines in regular expressions
Message-Id: <7v4qm0$ctt$1@nnrp1.deja.com>

I've looked around a lot, but can't seem to figure
out how to do this (or if it is even possible).

I want to use a subroutine in a regular expression, like this:

sub my_routine() {"hi";}
#I want to do something like this
s/&my_routine/bye/;
#instead of this
s/hi/bye/;
#or this
$hi = my_routine();
s/$hi/bye;

TIA,
Mark



Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Tue, 26 Oct 1999 12:33:08 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: subroutines in regular expressions
Message-Id: <44l4v7.8kb.ln@magna.metronet.com>

Mark Lofdahl (mel@disc.com) wrote:

: I've looked around a lot, but can't seem to figure
: out how to do this (or if it is even possible).


   The key to finding the answer is to realize that the PATTERN
   part of s/// is "double quotish", that is, it works like
   a double quoted string.

   So then your question becomes:

      "How do I expand function calls in a string?"

   And that is answered in Perl FAQ part 4.

   :-)


: I want to use a subroutine in a regular expression, like this:

: sub my_routine() {"hi";}
: #I want to do something like this
: s/&my_routine/bye/;



--
    Tad McClellan                          SGML Consulting
    tadmc@metronet.com                     Perl programming
    Fort Worth, Texas


------------------------------

Date: Tue, 26 Oct 1999 13:53:49 -0700
From: Larry Rosler <lr@hpl.hp.com>
Subject: Re: subroutines in regular expressions
Message-Id: <MPG.127fb4babdf650ac98a130@nntp.hpl.hp.com>

In article <7v4qm0$ctt$1@nnrp1.deja.com> on Tue, 26 Oct 1999 18:08:04 
GMT, Mark Lofdahl <mel@disc.com> says...
> I've looked around a lot, but can't seem to figure
> out how to do this (or if it is even possible).
> 
> I want to use a subroutine in a regular expression, like this:
> 
> sub my_routine() {"hi";}
> #I want to do something like this
> s/&my_routine/bye/;
> #instead of this
> s/hi/bye/;
> #or this
> $hi = my_routine();
> s/$hi/bye;

The regex is a double-quotish environment, so the answer is in perlfaq4: 
"How do I expand function calls in a string?"  Here's one way (scalar 
context):

    s/${\my_routine()}/bye/;

-- 
(Just Another Larry) Rosler
Hewlett-Packard Laboratories
http://www.hpl.hp.com/personal/Larry_Rosler/
lr@hpl.hp.com


------------------------------

Date: 27 Oct 1999 12:37:15 GMT
From: mgm@unpkhswm04.bscc.bls.com (Mitchell Morris)
Subject: Surely my pain is worth something ...
Message-Id: <slrn81dsfq.lga.mgm@unpkhswm04.bscc.bls.com>

I've recently completed a long, arduous, needlessly painful adventure
embedding Perl, Python, and Tcl into a single application. I spent a
good deal of time spelunking through source code, core dumps, and
single-stepping debug traces. After it was all done with, I wanted to
try to recover something from the pain of birthing this beastie.

Consequently, I've written a paper. If you have any interest and/or
expertise in embedding any of Perl, Python, or Tcl, I would be very
interested in getting your feedback.

The paper is at
        http://www.morrisland.com/~mitchell/



The most painful/irritating part is that I seem to be unable to pass a "-I"
flag to the embedded Perl interpreter without a heap crush following soon
after.  I have a small-ish C++ source that demonstrates the problem, but I
haven't been able to verify the problem exists across more than the machines
available to me at work (IBM RS/6000 with AIX 3.2.5, 4.1.5, and 4.3.2).

I'm not yet convinced that it's not something I'm doing to myself, so I'm
most assuredly not reporting it as a Perl bug. I'm still irked, however. If
you'd care to see what I'm doing, e-mail me and I'll send you my test code.
If there's enough interest, I'll post it.


Thanks for your attention,
+Mitchell




-- 
Mitchell Morris

Lies, damned lies, and Usenet posts


------------------------------

Date: Tue, 26 Oct 1999 18:23:11 +0200
From: "Steffan S. Fallesen" <ssf@fallesen-internet.dk>
Subject: Sv: Make Dir.
Message-Id: <YykR3.321$wo.678@news.get2net.dk>

Just:

mkdir "dir"; ???


-Steffan


BARBET Alain <abarb@nmg.fr> skrev i en
nyhedsmeddelelse:3815D01A.E44F4B7D@nmg.fr...
> perldoc -f mkdir
> a+
> --
> Alain BARBET
> abarb@nmg.fr - http://www.citeweb.net/alian
>
>




------------------------------

Date: Tue, 26 Oct 1999 17:38:07 GMT
From: michel.dalle@usa.net (Michel Dalle)
Subject: Re: Sv: Make Dir.
Message-Id: <7v4p83$oj8$1@news.mch.sbs.de>

In article <YykR3.321$wo.678@news.get2net.dk>, "Steffan S. Fallesen" <ssf@fallesen-internet.dk> wrote:
>BARBET Alain <abarb@nmg.fr> skrev i en
>nyhedsmeddelelse:3815D01A.E44F4B7D@nmg.fr...
>> perldoc -f mkdir
>> a+
>> --
>> Alain BARBET
>> abarb@nmg.fr - http://www.citeweb.net/alian
>Just:
>
>mkdir "dir"; ???
>

*** warning : the following is NOT a true story ***

Did you try it ? What happened ? Did you receive an error
message in the style 'Not enough arguments for mkdir' ?

Did you then decide to have a look at the documentation
after all, as Alain suggested ? No ? Well, do that now...




Yes, I mean NOW !

*** sound of Steffan reading the documentation ***





OK, welcome back. Did you understand it all ? Maybe you
might want to have a look at 'umask' too, no ?
So try 'perldoc -f umask' now.





All done ? What, you mean you didn't read it yet ?
Come on, we're WAITING...

*** sound of Steffan reading the documentation ***





Ah, there you are again. So, did that help ? Not very clear,
huh? But read what it says about directories again, and
you'll be ready for action.

*** sound of Steffan reading the documentation ***





Did you find what I mean ? All set for writing your script now ?
OK, you can start typing now.





All done ? What, you didn't try it yet ? Come on, this is
your chance !

*** sound of Steffan typing ***





*** sound of Steffan shouting and jumping up and down ***




It worked, right ? Amazing how reading the documentation
can make you feel happy !

The end...

Michel.
P.S. : Caution - reading the Perl documentation can be habit-forming


------------------------------

Date: Wed, 27 Oct 1999 19:58:32 GMT
From: fred <howitgolook@my-deja.com>
Subject: sysread / syswrite ?
Message-Id: <s1emb8svr0840@corp.supernews.com>

1. What are they?
2. Are they Un*x-specific?
3. Are there alternatives for them in Perl for Win95?

thanx.

--
Posted via CNET Help.com
http://www.help.com/


------------------------------

Date: Wed, 27 Oct 1999 16:45:19 -0700
From: David Cassell <cassell@mail.cor.epa.gov>
Subject: Re: sysread / syswrite ?
Message-Id: <38178E8F.9E85A1B@mail.cor.epa.gov>

fred wrote:
> 
> 1. What are they?

Just type the following to get complete discussions:

perldoc -f sysread
perldoc -f syswrite

> 2. Are they Un*x-specific?

No.  Give them a try.  Hey, what could happen?

> 3. Are there alternatives for them in Perl for Win95?

[See answer to #2]  No alternative needed.

But... you may want to look at the angle operator <FILE>
and the print() function too.  They may do what you want.

David
-- 
David Cassell, OAO                     cassell@mail.cor.epa.gov
Senior computing specialist
mathematical statistician


------------------------------

Date: Mon, 25 Oct 1999 09:33:43 GMT
From: Erik H. <sn192he@uni-duisburg.de>
Subject: system() call hangs, child is defunct
Message-Id: <7v185n$pgo$1@nnrp1.deja.com>

Hey!

Does anyone know this problem:

We do the following inside a perl script

system("echo starting work");

 ... calling lots of other modules, functions ...

system("echo work stopped");

We see the 'work stopped' output (or whatever we do inside
of the second system call)
but perl never comes back from the system call.
The child process started by the system call is
listed as 'defunct'.
(defunct = child process died but the parent process can
 not be informed because the parent process never
 entered 'wait' state!?)

Has anyone seen this before?

I wonder if it is possible to mess around with the
Unix-System (signal handling ...) so that the
system call isn't able to enter 'wait' state...
But maybe something else if faulty and we only
see some side effect.

Thankx for your help and comments,
    Erik.











Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Wed, 27 Oct 1999 11:43:34 -0700
From: Tom Phoenix <rootbeer@redcat.com>
Subject: Re: system() call hangs, child is defunct
Message-Id: <Pine.GSO.4.10.9910271141000.29843-100000@user2.teleport.com>

On 27 Oct 1999, M.J.T. Guy wrote:

> Tom Phoenix  <rootbeer@redcat.com> wrote:
> >
> >It sounds as if perl isn't reaping the child process. Are you 
> >setting a $SIG{CHLD} handler which is messing this up? Maybe you 
> >want to set that to 'IGNORE'.
> 
> Eeek!   That's the one thing you don't want to do  -  it'll eat all
> your exit codes.     

I said "maybe". Maybe you don't want that. :-)

> Set to 'DEFAULT' or better ensure it's not set at all.

What do you mean by "not set at all"? Does some system offer a different
behavior than 'IGNORE' or 'DEFAULT' provides?

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



------------------------------

Date: 27 Oct 1999 14:38:32 GMT
From: mjtg@cus.cam.ac.uk (M.J.T. Guy)
Subject: Re: system() call hangs, child is defunct
Message-Id: <7v72p8$8ao$1@pegasus.csx.cam.ac.uk>

Tom Phoenix  <rootbeer@redcat.com> wrote:
>
>It sounds as if perl isn't reaping the child process. Are you setting a
>$SIG{CHLD} handler which is messing this up? Maybe you want to set that to
>'IGNORE'.

Eeek!   That's the one thing you don't want to do  -  it'll eat all
your exit codes.     Set to 'DEFAULT' or better ensure it's not set
at all.


Mike Guy


------------------------------

Date: Wed, 27 Oct 1999 12:19:24 GMT
From: Erik H. <sn192he@uni-duisburg.de>
Subject: Re: system() call hangs, child is defunct
Message-Id: <7v6qka$pvp$1@nnrp1.deja.com>

In article <Pine.GSO.4.10.9910251343480.29843-
100000@user2.teleport.com>,
  Tom Phoenix <rootbeer@redcat.com> wrote:
> On Mon, 25 Oct 1999, Erik H. wrote:
>
> > We do the following inside a perl script
> >
> > system("echo starting work");
>
> What's wrong with perl's print function?
There is nothing wrong with the 'print' function.
This is only an example. The original system() call
does something more complicated...

>
> > ... calling lots of other modules, functions ...
> >
> > system("echo work stopped");
> >
> > We see the 'work stopped' output (or whatever we do inside
> > of the second system call)
> > but perl never comes back from the system call.
> > The child process started by the system call is
> > listed as 'defunct'.
>
> It sounds as if perl isn't reaping the child process. Are you setting
a
> $SIG{CHLD} handler which is messing this up? Maybe you want to set
that to
> 'IGNORE'.
>
> Good luck!
>
> --
> Tom Phoenix       Perl Training and Hacking       Esperanto
> Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/


Thankx to all who answered but we found the solution yesterday.
After all of the (perl-) developers refused to do some
proper (perl-) debugging I did it myself.
I found out where exactly the problem starts and so we found
out that someone included an old version of a database library.

Bye,
   Erik.


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Tue, 26 Oct 1999 10:18:17 -0400
From: Bernie Cosell <bernie@fantasyfarm.com>
Subject: Re: system() call hangs, child is defunct
Message-Id: <8LYVOIMH4l821j3MxL6NMSHq3BfK@4ax.com>

Erik H. <sn192he@uni-duisburg.de> wrote:

} We do the following inside a perl script
} 
} system("echo work stopped");
} 
} We see the 'work stopped' output (or whatever we do inside
} of the second system call)
} but perl never comes back from the system call.
} The child process started by the system call is
} listed as 'defunct'.
 [...]

} Has anyone seen this before?

This looks similar to the problem I had running Perl scripts out of crond:
check that you're not ignoring SIGCHLD.  In several of my scripts, up at
the top, I've had to stick in:

$SIG{'CHLD'} = 'DEFAULT' ;   # Workaround for problem with crond

  /Bernie\
-- 
Bernie Cosell                     Fantasy Farm Fibers
bernie@fantasyfarm.com            Pearisburg, VA
    -->  Too many people, too few sheep  <--          


------------------------------

Date: Mon, 25 Oct 1999 13:45:39 -0700
From: Tom Phoenix <rootbeer@redcat.com>
Subject: Re: system() call hangs, child is defunct
Message-Id: <Pine.GSO.4.10.9910251343480.29843-100000@user2.teleport.com>

On Mon, 25 Oct 1999, Erik H. wrote:

> We do the following inside a perl script
> 
> system("echo starting work");

What's wrong with perl's print function?

> ... calling lots of other modules, functions ...
> 
> system("echo work stopped");
> 
> We see the 'work stopped' output (or whatever we do inside
> of the second system call)
> but perl never comes back from the system call.
> The child process started by the system call is
> listed as 'defunct'.

It sounds as if perl isn't reaping the child process. Are you setting a
$SIG{CHLD} handler which is messing this up? Maybe you want to set that to
'IGNORE'.

Good luck!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



------------------------------

Date: Wed, 27 Oct 1999 12:22:55 -0700
From: oneill78 <oneillNOonSPAM@cs.uregina.ca.invalid>
Subject: test
Message-Id: <0237dd28.e8408b9c@usw-ex0110-073.remarq.com>

test


* Sent from AltaVista http://www.altavista.com Where you can also find releated Web Pages, Images, Audios, Videos, News, and Shopping.  Smart is Beautiful


------------------------------

Date: Mon, 25 Oct 1999 13:20:02 -0700
From: Tom Phoenix <rootbeer@redcat.com>
Subject: Re: Text::Template and -T
Message-Id: <Pine.GSO.4.10.9910251319140.29843-100000@user2.teleport.com>

On Sun, 24 Oct 1999, Archie Warnock wrote:

> I'm using the Text::Template module in a CGI script to insert some
> dynamically-generated text into an HTML page.  When I add the -T taint
> flag to the script, it croaks, complaining about an insecure variable
> in the module.

> is there a fix for this, 

Sure there is. Be sure to send the patch to the module's author when
you've written it. :-)

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



------------------------------

Date: Mon, 25 Oct 1999 20:59:38 GMT
From: damon@nic.cc
Subject: Thesaurus Module/Data?
Message-Id: <7v2gbo$nlc$1@nnrp1.deja.com>

Hi. I'm hoping somebody out there has done this before...

I'm trying to incorporate a thesaurus into a web-based application to
enable "fuzzy" searches, etc. It's a fairly straightforward concept, but
I haven't been able to find much out there. Basically what I need, at
miniumum, is the actual thesaurus data for the lookup. Could be a
database, could be a text file- I don't really care. Search algorithmns
would be nice, but I could write those...

Anyone have any ideas? I'm hoping it will not cost me too much.

Thanks,
Damon


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Tue, 26 Oct 1999 11:36:18 GMT
From: "Craig Vincent" <2bunnyhop@home.com>
Subject: Re: Thesaurus Module/Data?
Message-Id: <SmgR3.15651$Ua7.534892@news2.rdc1.on.home.com>

> I'm trying to incorporate a thesaurus into a web-based application to
> enable "fuzzy" searches, etc. It's a fairly straightforward concept, but
> I haven't been able to find much out there. Basically what I need, at
> miniumum, is the actual thesaurus data for the lookup. Could be a
> database, could be a text file- I don't really care. Search algorithmns
> would be nice, but I could write those...

Text::Thesaurus::ISO
Module          Thesaurus
Module          Thesaurus::DBI
Module          Thesaurus::DBM
Module          Thesaurus::File

These were some of the "potential" modules the CPAN shell came up with for a
thesaurus.  I haven't actually used any of them myself but you may want to
look into these for your answers.

Sincerely,

Craig Vincent




------------------------------

Date: 25 Oct 1999 05:46:54 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: this darn error
Message-Id: <slrn818d85.fji.abigail@alexandra.delanet.com>

Mikee (mikee@bnis.net) wrote on MMCCXLI September MCMXCIII in
<URL:news:s0rvu7o5r0189@corp.supernews.com>:
## every time i try to run a .pl file i get this error
## 
## <offline mode> : entername=value pairs on standard input
## 
## do you know why i get this?

Sure. Your program prints it to STDOUT.

Most likely, this happens because it's using CGI.pm.

## i dont check the board alot so email me your suggestions thanx in advance

Oh, then I guess you don't really need to know the answer.

## my email addy is mikee@bnis.net


What are email addies?



Abigail
-- 
perl -MNet::Dict -we '(Net::Dict -> new (server => "dict.org")
                       -> define ("foldoc", "perl")) [0] -> print'


  -----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
   http://www.newsfeeds.com       The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including  Dedicated  Binaries Servers ==-----


------------------------------

Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 16 Sep 99)
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: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.

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 V9 Issue 1201
**************************************


home help back first fref pref prev next nref lref last post