[6978] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 603 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Jun 12 02:08:47 1997

Date: Wed, 11 Jun 97 23:00:22 -0700
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, 11 Jun 1997     Volume: 8 Number: 603

Today's topics:
     Re: #ifdef in XS ? <dada@divinf.it>
     Re: Can you write about Perl? (Jon Orwant)
     CGI: remaining on same page after POSTing form <wayne@amerisites.com>
     Disk Space and Free INODES <kane@accesscomm.net>
     global regex in an "if" statement <staci@datahost.com>
     Re: How to call TELNET from within a script? (I R A Aggie)
     Re: How to Open a Window in a Perl Script for a Web Pag (Nathan V. Patwardhan)
     hpux perl 5.003 binaries <rligonzo@geocities.com>
     MacPerl calling other Scripts-HELP <kerry@lumber.com>
     Mail using Perl <mhagler@cse.unl.edu>
     Re: Mail using Perl (Tung-chiang Yang)
     Re: Mail using Perl <sdcote@lci.net>
     Re: Mail using Perl (Neil Briscoe)
     Re: multiple white spaces <ajohnson@gpu.srv.ualberta.ca>
     Re: Newbie:To PUSH or not to PUSH? (Eric Roode)
     Re: Perl Compiler & Modules (follow-up) <bah@mail.med.cornell.edu>
     PERL for VMS and Windows 95' <patton@micro.ti.com>
     Re: perl joke of the day ? <Michael.Cameron@MCI.com>
     Re: perl joke of the day ? <stuartc@ind.tansu.com.au>
     Re: Problem with Net::POP3 (Neil Briscoe)
     Re: Running CGI in the background <rootbeer@teleport.com>
     Re: Standalone web database for Perl? <fprice@ai.uga.edu>
     XS:Keeping a variable btwn c calls <jheck@merck.com>
     XS:Keeping a variable btwn c calls <jheck@merck.com>
     Re: XS:Keeping a variable btwn c calls <jheck@merck.com>
     Re: Y2K Compliant? <rootbeer@teleport.com>
     Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)

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

Date: Wed, 11 Jun 1997 18:53:36 +0200
From: Aldo Calpini <dada@divinf.it>
To: Jeffery Chow <jefferyc@mail.unixg.ubc.ca>
Subject: Re: #ifdef in XS ?
Message-Id: <339ED810.DBB5E930@divinf.it>

Jeffery Chow wrote:
> 
> As far as I know, CPP requires the hash mark to be at the beginning of
> the line:

You're right! Thanks a lot... :-)

Bye,
Aldo Calpini
---/\-----------------------------------------------------------
--/  \--------------------------------- mailto:dada@divinf.it --
-<dada>-- POPULUS VULT DECIPI, -------- mailto:sis@divinf.it ---
--\  /------- ERGO DECIPIATUR --------- http://sis.divinf.it ---
---\/-----------------------------------------------------------


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

Date: 11 Jun 1997 15:16:02 GMT
From: orwant@fahrenheit-451.media.mit.edu (Jon Orwant)
To: philipp@saji.com (Philip Pendleton)
Subject: Re: Can you write about Perl?
Message-Id: <ORWANT.97Jun11111602@fahrenheit-451.media.mit.edu>


philipp@saji.com (Philip Pendleton) writes:

   Coded Magazine is a monthly online programming magazine that looks at all 
   aspects of computer programming including web development.

   If you can write both interesting and informative articles aimed at the 
   novice and intermediate programmer, we'd love to hear from you.

As would The Perl Journal, a quarterly paper Perl magazine.  :-)

-Jon

----------------
Jon Orwant
The Perl Journal
http://tpj.com/




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

Date: Wed, 11 Jun 1997 13:05:33 -0400
From: Wayne Cohoe <wayne@amerisites.com>
Subject: CGI: remaining on same page after POSTing form
Message-Id: <339EDADD.488C@amerisites.com>

Hi all,

I'd like to be able to submit a form, then
instead of my perl script returning a page:

"Your form was processed.
Hit Back to continue."

I'd like the browser to just remain on the
page that the form was on, and in the same
spot also.

Obviously, I could have the cgi script just
dump the file to the browser, but the form
is not on the same file system, so a direct
read is not possible.

Any ideas?

I'd also be grateful if anyone would be
willing to point me to a newsgroup for
perl-cgi if there is one. I hate to post
inappropriately, but I really need a hand. 

Best Regards,
Wayne Cohoe


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

Date: Wed, 11 Jun 1997 11:56:46 -0500
From: The Old Wolf <kane@accesscomm.net>
Subject: Disk Space and Free INODES
Message-Id: <339ED8CE.5C82@accesscomm.net>

I've searched through DejaNews and the FAQ's a few times and can't seem
to find what I'm looking for.

I need a platform independent method of determining free space in a file
system (Preferably faster then writing a test file till it fails ;) )

And I need a UNIX independent method of determining the available
INODES.

The freespace problem is flexible as I can tolerate, say a max of three,
different methods determined by platform with an initial test of which
platform I'm on.

The logic behind all this is I'm working on what is INTENDED to be a
cross platform program to work through and collate some 40k or more
independent files into blocks by related topic, since the whole
collation process will probably take a good amount of time in the first
place, the last thing my users are gonna want to see is "Doh! Too bad,
your an hour into the job and out of space, tough luck...".
				Any ideas would be appreciated
				kane@accesscomm.net


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

Date: Wed, 11 Jun 1997 10:24:30 -0700
From: Michael Stearns <staci@datahost.com>
Subject: global regex in an "if" statement
Message-Id: <339EDF4E.676D@datahost.com>

I have a large (by my standards) regex script. I have taken input and
put it into one scalar variable and then do a bunch of global
replacements. My problem is with the if statement at the bottom. I
cannot figure out how to make this work globally. It only works on the
first instance that it matches.

Are there any modifiers I can use to make this work globally or are
there other techniques that will make it work?

Thanks,
Michael Stearns

################################
foreach (@ARGV) {

open (INFILE,"$_") || die ("Cannot Open $_\n");

@text=<INFILE>;
$text=join("",@text);

<--------lots of other stuff in here----------------->

####This is what many of my lines look like. This works well for doig a
global search and replace.

$text=~ s^foo^bar^gs;

#### Here's where I am stuck. This only works on one instance and I so
far can't get any modifiers to make it work differently.

if ( $text =~ /foo/ &&  $text !~ /bar/) {

print "YEAH\n";
}
###################################


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

Date: Wed, 11 Jun 1997 09:44:29 -0500
From: fl_aggie@hotmail.com (I R A Aggie)
Subject: Re: How to call TELNET from within a script?
Message-Id: <fl_aggie-ya02408000R1106970944290001@news.fsu.edu>

In article <199706111232.FAA08065@fat.doobie.com>, nobody@huge.cajones.com
(Huge Cajones Remailer) wrote:

+ Can someone show me (or tell me where to look to find out) how to
+ start an interactive telnet session from within a script? 

Yep. Go to CPAN <url:http://www.perl.com/CPAN/> and find the 
Net::Telnet module. It used to be part of the libnet distribution,
but is now unbundled.

Its extensively documented, with many examples.

James

-- 
Consulting Minister for Consultants, DNRC
Support the anti-Spam amendment <url:http://www.cauce.org/>
To cure your perl CGI problems, please look at:
<url:http://www.perl.com/perl/faq/idiots-guide.html>


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

Date: 12 Jun 1997 04:21:13 GMT
From: nvp@shore.net (Nathan V. Patwardhan)
Subject: Re: How to Open a Window in a Perl Script for a Web Page???
Message-Id: <5nntfp$lcr@fridge-nf0.shore.net>

$j,u?OE" (swsung.bbs@cis.nctu.edu.tw) wrote:
: In a Java script for a Web page, we can open a window by using
: the window.open function. Is it possible to do this in a Perl
: script for a web page??? How???

You'll have to read the documentation accompanying CGI.pm or
check out comp.infosystems.www.authoring.cgi.


--
Nathan V. Patwardhan
nvp@shore.net



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

Date: Wed, 11 Jun 1997 18:45:18 +0200
From: RL <rligonzo@geocities.com>
Subject: hpux perl 5.003 binaries
Message-Id: <339ED61E.3B58@geocities.com>

Hi at all , our problem is to retrieve the binaries version of perl
5.003 for hp-ux v.10.10 , we have find one but it seems not work fine
_(depot file), may anybody help us to find the correct one if exist???

Thank you....


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

Date: Wed, 11 Jun 1997 10:06:18 -0700
From: Kerry Cakebread <kerry@lumber.com>
Subject: MacPerl calling other Scripts-HELP
Message-Id: <339EDAEE.903@lumber.com>

I'm trying to write a perl cgi for the Mac that takes input from an HTML
form, then repeatedly calls another CGI, parses the 2nd CGI's output,
and consolidates the resulting outputs into a single HTML response
document.  Unfortunately, it looks like the Perl for the Mac I have
hasn't implemented `script`, system(), exec(), or fork(), so I can't
actually call the 2nd script.

It's great that I can call AppleScripts, or embed them in my perl
scripts, but it's a compiled CGI (no source) that I need to access.

HELP anyone????!!!

Kerry

kerry@lumber.com


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

Date: Wed, 11 Jun 1997 11:00:09 -0500
From: Mark Hagler <mhagler@cse.unl.edu>
Subject: Mail using Perl
Message-Id: <339ECB89.D376E9A7@cse.unl.edu>

Hi,
	I am working on a website , using Perl.What I want to know is that how
can we send mail to a particular address from the web site.The web site
is for people giving online exams, the results need to be sent to a
particular address.
				Thanx
					Sameer


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

Date: Thu, 12 Jun 1997 02:14:59 GMT
From: tcyang@netcom.com (Tung-chiang Yang)
Subject: Re: Mail using Perl
Message-Id: <tcyangEBn4wz.K4o@netcom.com>

People have already provided you with enough suggestions.  I would add
one that I suggest you log all the transactions for their $ENV{'REMOTE_HOST'}.
I have been forged subscribed to tons of mailing lists, or being signed up
with tons of Web sites to send me E-mails I don't want, and therefore I
recommend you start logging before problems take place.

============================
Mark Hagler typed when the mommy tyrannosaurus found him:
: Hi,
: 	I am working on a website , using Perl.What I want to know is that how
: can we send mail to a particular address from the web site.The web site
: is for people giving online exams, the results need to be sent to a
: particular address.
: 				Thanx
: 					Sameer

--
Tung-chiang Yang                       tcyang@netcom.com

soc.culture.taiwan, soc.culture.china (by SCC FAQ Team) FAQ's:
   http://www.iglou.com/tcyang/Taiwan_faq.shtml, China_faq.shtml


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

Date: Wed, 11 Jun 1997 14:06:59 -0400
From: "Stephan D. Cote" <sdcote@lci.net>
To: Mark Hagler <mhagler@cse.unl.edu>
Subject: Re: Mail using Perl
Message-Id: <339EE943.E4D21E70@lci.net>

Mark Hagler wrote:

> Hi,
>         I am working on a website , using Perl.What I want to know is
> that how
> can we send mail to a particular address from the web site.The web
> site
> is for people giving online exams, the results need to be sent to a
> particular address.
>                                 Thanx
>                                         Sameer

All you have to do is write your message out to a temporary file, the
call a system command like
  system("mail mhagler\@cse.unl.edu < /tmp/stuff-to-mail.txt");






This is a simple CGI program that reads in an HTML form and mails the
data from the form:

#!/usr/local/bin/perl

do "cgi-lib.pl" || die "Fatal Error: Can't load cgi library";

&ReadParse;

print "Content-type: text/html\n\n";
print "<HTML>";
print "<HEAD><TITLE>Thank You\!</TITLE>";
print "</HEAD><BODY>";
print "<H2>Thank you\!</H2>";
print "We value your input\!";
print "<P>";
print "We've recorded your input and are currently reviewing it.\n";
print "<HR>";
print "<H3>Back to the <A HREF=\"../index.html\">";
print "Home Page</A></H3>";
print "</BODY></HTML>";

$pid=$$;

open(COMMENTSFILE,">/tmp/comment.$pid");
print COMMENTSFILE "Comments\n";
print COMMENTSFILE "   Name:   $in{'name'}\n";
print COMMENTSFILE "   Phone:  $in{'phone'}\n";
print COMMENTSFILE "   Email:  $in{'email'}\n";
print COMMENTSFILE "Rating: $in{'rating'}\n";
print COMMENTSFILE "- - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - -\n";
print COMMENTSFILE "Comments:\n";
print COMMENTSFILE "$in{'comments'}";
close COMMENTSFILE;
$command="mail mhagler\@cse.unl.edu < /tmp/comment.$pid";
system($command);
unlink("/tmp/comment.$pid");


This is a very simple example, but you should get an idea.


--
---[Stephan D. Cote, CCP]------[ Sr. Network Engineer ]---
       Data Engineering,  LCI International Inc.
       4650 Lakehurst Court,  Dublin, OH  43016
---[ (614) 798-6000 ]-------------------------------------




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

Date: 11 Jun 1997 19:12:39 GMT
From: neilb@zetnet.co.uk (Neil Briscoe)
Subject: Re: Mail using Perl
Message-Id: <memo.19970611201239.2277G@skep.compulink.co.uk.cix.co.uk>

In article <339ECB89.D376E9A7@cse.unl.edu>, mhagler@cse.unl.edu (Mark
Hagler) wrote:

> Hi,
> 	I am working on a website , using Perl.What I want to know is that
how
> can we send mail to a particular address from the web site.The web site
> is for people giving online exams, the results need to be sent to a
> particular address.
> 				Thanx
> 					Sameer
>

Running on an NT based web server are you?  Well, send mail to me - and
I'll reply with my smtp.pl module for NT perl - a hideous piece of coding,
based on the rather more pleasant smtp.pm - which I have yet failed to get
working under NT.

Regards
Neil



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

Date: Tue, 10 Jun 1997 23:20:01 -0500
From: Andrew Johnson <ajohnson@gpu.srv.ualberta.ca>
Subject: Re: multiple white spaces
Message-Id: <339E2771.9063BDE@gpu.srv.ualberta.ca>

Tri Duy Tram wrote:
! 
! I am wondering how do you change multiple white spaces to
! just one single white space? Lets suppose I have a string
! 
! $line = "This is a  line  that has multiple  white space";
!  
! to
! 
! $line = "This is a line that has multiple white spaces";
! 
! I tried:
! $_ = $line;
! s/^\s*(.*?)\s*$/$1/;
! 
! 
well, in that one you are trying to match the beginning
of the string, followed by zero-or-more whitespace thingies
followed by the minimal number of zero-or-more anthingies
(except newlines) which are followed by zero-or-more whitespace
thingies and the end of string---and you want to replace it
with just the zero-or-more anthingies? Does that sound like
"replace multiple whitespace thingies with a single space"?

no. what I think you think you are trying to do is to match
(something) optionally surrounded by whitespace and just
replace it with the (something)...not to mention the problem
with ^ and $. the problem is, (something) never occurs in
your original question...multiple whitespace does...

hmm...so try to match what you said instead...
multiple whitespace would be \s+  meaning one-or-more whitespace
thingies, so let's match that, and replace it with a space:

s/\s+/ /g;  #there is one space between the last two / /'s

ie; find one-or-more whitespace's and replace with one space...
the /g means do it repeatedly over the string. Sometimes, a regex
is as simple as the english statement of the problem :-)

! any help will be appreciated.  Thank you

you should read the FAQ's (maybe perlfaq4 and perlfaq6) and
the perlre manpage for more information.

regards
andrew
--
#!/usr/bin/perl -w
$_="7072696e74224a757374416e6f746865725065726c4641512765725c6e22";
s$^$join(" ",unpack("A5A5A7A4A9",pack("C*",
map {hex} m^#!(?:\/\w+)+?\/\(\w+)\s-w\^g)));
@?=?\(*\(?\(*\d\w^gx))).(\$1?"boo":"\n")$gee;


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

Date: Thu, 12 Jun 1997 02:46:46 GMT
From: sdn@mv.mv.com (Eric Roode)
Subject: Re: Newbie:To PUSH or not to PUSH?
Message-Id: <EBn6Dy.JwK@mv.mv.com>

In article <5nm5e4$8q6$1@power42t.hkbu.edu.hk>,
P.M.Wong  <s11976@ctsc.hkbc.hk> wrote:
>Being a newbie in perl, i often seen scripts that read the whole file
>into an array, so that further manipulation of the file can be done.
>There are mainly 2 ways of doing so:
>1. open (FILE, $filespec);
>@LINES=<FILE>;
>... etc
>
>2. open (FILE, $filespec);
> while (<FILE>) {
>  push(@lines, $_);
>  }
>
>I have some questions:
>a) For both methods, is there any limit on the size of the file that
>it won't break down, i.e. will all the lines in the FILE be read into
>the array @LINES , for most files ? If not, what are the max. size of FILE
>for these to work ok?

Perl has no such limits built into it. The only limit is how much
RAM your computer has. If you have 2Gb (as I do <smirk>), you can
slurp a 2Gb file.

>c) generally speaking, which method is preferable, 1 or 2  
>, i.e. under what circumstances do we use 1 and 2 ?

Choice #1 will generally be faster, since you don't have the 
overhead of the while(), and of placing each line into $_ before
pushing it onto @lines.
-- 
"I feel my body weakened by the years
 As people turn to gods of cruel design
 Is it that they fear the pain of death
 Or could it be they fear the joy of life?"  -- Toad The Wet Sprocket   


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

Date: Wed, 11 Jun 1997 08:46:13 -0400
From: Benjamin Holzman <bah@mail.med.cornell.edu>
To: psyclone@twd.net
Subject: Re: Perl Compiler & Modules (follow-up)
Message-Id: <339E9E15.758FBE43@mail.med.cornell.edu>

psyclone@twd.net wrote:
> 
> I thought an example of the errors might help.
> 
> Here's the code I want to compile :
> 
> #!/usr/bin/perl
> 
> $host = $ARGV[0];
> &usage unless $host;
> 
> use Net::Time qw(inet_daytime);
> print "\nTime on $host: ";
> print inet_daytime($host, 'tcp');
> print "\n";
> 
> sub usage {
>  print "\nUSAGE: get_time <host>\n\n";
>  exit;
> }
> 
> When I run "./get_time" it seems to work ok :
> 
> USAGE: get_time <host>
> 
> But here's the error I get when I run "./get_time localhost" :
> 
> Can't call method "new" in empty package "IO::Socket::INET" at
> /usr/lib/perl5/site_perl/Net/Time.pm line 36.

Well, I don't know for sure, 'cause I haven't played with the compiler
at all, but that phrase "empty package" sure sounds suspicious.  Does
/usr/lib/perl5/site_perl/IO/Socket.pm exist?

> 
> Thanks,
> 
> Allen
> 
> -------------------==== Posted via Deja News ====-----------------------
>       http://www.dejanews.com/     Search, Read, Post to Usenet

Benjamin Holzman


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

Date: Wed, 11 Jun 1997 14:21:51 -0400
From: "James D. Patton Jr." <patton@micro.ti.com>
Subject: PERL for VMS and Windows 95'
Message-Id: <339EECBF.2D09@micro.ti.com>

Does anyone know where I can get a copy of PERL for both VMS and
Windows95' O/S's? 

			JIM

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
		Texas Instruments, Inc.
James Patton		Novice Systems Administrator
                patton@micro.ti.com	
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=


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

Date: Wed, 11 Jun 1997 22:52:28 -0400
From: Michael J Cameron <Michael.Cameron@MCI.com>
Subject: Re: perl joke of the day ?
Message-Id: <339F646C.228E@MCI.com>

Steffen Beyer wrote:
> 

Or maybe the guy just needs some help.

Why poke fun at those who are less experienced than yourself?

Can't a newsgroup be educating instead of humiliating. People like you
make this forum a platform for elitist views instead of a free and frank
exchange of ideas.


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

Date: 12 Jun 1997 14:46:24 +1000
From: Stuart Cooper <stuartc@ind.tansu.com.au>
Subject: Re: perl joke of the day ?
Message-Id: <yeou3j4e8db.fsf@parakeet.ind.tansu.com.au>

The best joke perl I've found so far is this
(some names changed to protect the guilty)

if ( (system("cmd")/256) != 0) {
	print "Cmd failed\n";
	exit 1;
}

It isn't that funny with the superfluous "!= 0" but the added
useless "/256" makes it a minor classic.

Stuart Cooper
stuartc@tansu.ind.com.au


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

Date: 11 Jun 1997 19:12:32 GMT
From: neilb@zetnet.co.uk (Neil Briscoe)
Subject: Re: Problem with Net::POP3
Message-Id: <memo.19970611201231.2277F@skep.compulink.co.uk.cix.co.uk>

In article <5niaqa$ht1$1@shiva.usa.net>, wozz@wookie.net (w0zz) wrote:

> I'm writing a simple little pop client in perl for some testing applicat
> ions
> and have run into some problems with Net::POP3 from the libnet-1.0505 pa
> ckage.
>
> the script is below
>
>
> #!/usr/bin/perl
>
> use Net::POP3;
>
> $pop = Net::POP3->new('pophost',
>                       Timeout => 300);
>
> $pop->user('foo');
> $pop->pass('foo');
> $last = $pop->last();
>
> print "Last message accessed: $last\n";
>
> %list = $pop->list();
> foreach $key (sort keys %list){
>         print "$key\n";
> }
> $pop->quit();
>
>
>
> everything seems to work fine, no errors printed, the last message is
> printed, but nothing ever ends up in %list, the foreach doesn't run thro
> ugh
> even once because %list ends up being empty.  Perhaps i missed the usage
>  of
> the list() method, but the above doesn't work.  All i need is a list of
> the
> messages in a mailbox.  Any ideas?  This is on a Solaris 2.5.1 box runni
> gn
> Perl 5.003

I'm at home now, rather than at the system with my Net::POP3 module, but I
have a nasty feeling that the line which reads %list = $pop->list() should
actually read :-

*list = $pop->list()

This is because, if memory serves, $pop->list() returns a *reference* to a
hash, rather than the hash itself.

Once, you've modified your code to the line above, I think you may find
the rest works as you expect.

Regards
Neil



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

Date: Wed, 11 Jun 1997 11:03:43 -0700
From: Tom Phoenix <rootbeer@teleport.com>
To: Mike Stok <mike@stok.co.uk>
Subject: Re: Running CGI in the background
Message-Id: <Pine.GSO.3.96.970611105645.18839F-100000@kelly.teleport.com>

On 10 Jun 1997, Mike Stok wrote:

> But surely perl is a language and CGI is an protocol and it's quite
> possible to write programs which adhere to the CGI protocol in the
> language perl...

True enough. But what would happen if you asked, "How do I drive my Toyota
to Disney World?" in a Toyota newsgroup? 

Since the message I replied to was about a problem concerning webservers,
it should not have been in a Perl newsgroup. Admittedly, there are some
gray areas, but some messages are surely off topic.

Like this one. :-)

-- Tom Phoenix        http://www.teleport.com/~rootbeer/
rootbeer@teleport.com   PGP  Skribu al mi per Esperanto!
Randal Schwartz Case:  http://www.rahul.net/jeffrey/ovs/




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

Date: Fri, 6 Jun 1997 10:32:39 -0400
From: Frank Price <fprice@ai.uga.edu>
Subject: Re: Standalone web database for Perl?
Message-Id: <Pine.SUN.3.91.970606103123.27295C-100000@aisun2.ai.uga.edu>

On 30 May 1997, Bruce Schiller wrote:

> Hidden (guess@somewhere.com) wrote:
> : depending on how large the Database file will be you may not even need a
> : Database management system.  Perl can work with text files with the fields
> : on separate lines and the records separated with a blank line.
> 
> Gary.....
> 
> Check out Randall's Tiny Database article he wrote for his Unix World
> column about two year's ago.  In it he shows sample code how to parse out
> the records (set up as above) and sort them various ways.  With a little
> work you can make it do anything you want. 
> 
> It's on his website, along with the rest of the very informative Unix
> World articles, but you'll have to search a little since I don't have the
> url at the moment.
> 
Here's that address ...

	http://w3.stonehenge.com/merlyn/UnixReview/col04.html

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Frank Price					fprice@ai.uga.edu
Dept. of Philosophy				www.ai.uga.edu/students/fprice
University of Georgia				(706)353-6756

	BIG IDEA OF THE MILLENIUM:  People like shiny things.
				-from Suck, Sept. 4 1996





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

Date: Wed, 11 Jun 1997 13:05:15 -0400
From: James Heck <jheck@merck.com>
Subject: XS:Keeping a variable btwn c calls
Message-Id: <339EDACB.41C6@merck.com>

I would like to call one C program from my Perl file, get it's 
return value as well keep track of a pointer it used.  I then
need to make that pointer available to another C program.   

        Can i just put the variable in the OUTPUT section
of my .xs file where i have the function prototype?  
        But tehn how do I make it available to the C program?  
Is there a way with out passing it as a parameter to the second 
C program?

        Any ideas would be great.  
TIA,
        James

-- 
--------------------
James J. Heck
jheck@acm.org
http://www.bucknell.edu/~jheck


       The contents of this message express only the sender's opinion.
       This message does not necessarily reflect the policy or views of
       my employer, Merck & Co., Inc.  All responsibility for the statements
       made in this Usenet posting resides solely and completely with the
       sender.


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

Date: Wed, 11 Jun 1997 13:14:45 -0400
From: James Heck <jheck@merck.com>
Subject: XS:Keeping a variable btwn c calls
Message-Id: <339EDD05.2781@merck.com>

I would like to call one C program from my Perl file, get it's 
return value as well keep track of a pointer it used.  I then
need to make that pointer available to another C program.   

        Can i just put the variable in the OUTPUT section
of my .xs file where i have the function prototype?  
        But tehn how do I make it available to the C program?  
Is there a way with out passing it as a parameter to the second 
C program?

        Any ideas would be great.  
TIA,
        James

--------------------
James J. Heck
jheck@acm.org
http://www.bucknell.edu/~jheck


       The contents of this message express only the sender's opinion.
       This message does not necessarily reflect the policy or views of
       my employer, Merck & Co., Inc.  All responsibility for the statements
       made in this Usenet posting resides solely and completely with the
       sender.


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

Date: Wed, 11 Jun 1997 13:10:00 -0400
From: James Heck <jheck@merck.com>
Subject: Re: XS:Keeping a variable btwn c calls
Message-Id: <339EDBE8.167E@merck.com>

Sorry, my email was wrong, please respond to jheck@acm.org if you are
responding privately.
	Thanks and again sorry for the mixup.
James
-- 
--------------------
James J. Heck
jheck@acm.org
http://www.bucknell.edu/~jheck


       The contents of this message express only the sender's opinion.
       This message does not necessarily reflect the policy or views of
       my employer, Merck & Co., Inc.  All responsibility for the statements
       made in this Usenet posting resides solely and completely with the
       sender.


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

Date: Wed, 11 Jun 1997 11:24:32 -0700
From: Tom Phoenix <rootbeer@teleport.com>
To: Gnome <gnome@advicom.net>
Subject: Re: Y2K Compliant?
Message-Id: <Pine.GSO.3.96.970611110403.18839G-100000@kelly.teleport.com>

On Tue, 10 Jun 1997, Gnome wrote:

> So what if it is in the FAQ?  

What's the point of having a FAQ list if it isn't used? 

We maintain a FAQ to save the time and trouble of three groups of people. 

  * People who answer questions can answer just the new ones.

  * People who need answers can find them quickly.

  * People who are reading the newsgroup can find interesting things more
    easily.

And, of course, the load on Usenet is lower, so we're all better off.

> This IS a place to post questions about Perl is it not? 

No. This is a place to post non-FAQ questions about Perl, and a few other
things related to Perl. Post FAQs to misc.test. :-)

> And someone looking for a quick answer should expect to receive such
> answers here, should they not?

No, they should get the answers much _more_ quickly by reading the docs
and FAQs. 

-- Tom Phoenix        http://www.teleport.com/~rootbeer/
rootbeer@teleport.com   PGP  Skribu al mi per Esperanto!
Randal Schwartz Case:  http://www.rahul.net/jeffrey/ovs/



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

Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 8 Mar 97)
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.  

To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.

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.

The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.

The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.

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 V8 Issue 603
*************************************

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