[17706] in Perl-Users-Digest
Perl-Users Digest, Issue: 5126 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Dec 15 18:11:46 2000
Date: Fri, 15 Dec 2000 15:10:17 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <976921817-v9-i5126@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Fri, 15 Dec 2000 Volume: 9 Number: 5126
Today's topics:
Re: Problem using Image::Size on a webserver (brian d foy)
Re: Regex can't be greedy with /(a|ab)/ ? <uri@sysarch.com>
Re: Regex can't be greedy with /(a|ab)/ ? <ren.maddox@tivoli.com>
Re: Regex can't be greedy with /(a|ab)/ ? <uri@sysarch.com>
Regular Expression Help <jswartz@sentiat.com>
Rewriting a script to make so it can run in background. <ncheung@draper.com>
Re: Rewriting a script to make so it can run in backgro (Richard Zilavec)
Re: Splitting on more than one character (Ben Okopnik)
Re: Splitting on more than one character <ren.maddox@tivoli.com>
Re: stripping info, transposing info <jdhunter@nitace.bsd.uchicago.edu>
Re: Stripping out meta tags from web pages <jb@yperite.demon.co.uk>
Re: Total Beginner <ekulis@apple.com>
Re: Truncate A Log File <cbah@chez.com>
Re: Truncate A Log File <bart.lateur@skynet.be>
Re: using PERL for process automation <cbah@chez.com>
Re: Why are multiple zeroes true? (Craig Berry)
Re: Why are multiple zeroes true? <iltzu@sci.invalid>
Re: Why are multiple zeroes true? <uri@sysarch.com>
Re: WIN REGISTRY QUESTION <jb@yperite.demon.co.uk>
Re: Windows cant recognize the original owner <Alessandro.Augusto@br.bosch.com>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 15 Dec 2000 16:33:37 -0400
From: brian@smithrenaud.com (brian d foy)
Subject: Re: Problem using Image::Size on a webserver
Message-Id: <brian-ya02408000R1512001633370001@news.panix.com>
In article <4a2d0501d2g.soper@soundhouse.co.uk>, Geoff Soper <g.soper@soundhouse.co.uk> posted:
> In article <976744359.28205@itz.pp.sci.fi>,
> Ilmari Karonen <iltzu@sci.invalid> wrote:
> > What happened when you tried it? (rhetorical question)
> I'm very skepical of assuming if something work that it's OK without
> knowing so. I like to know something is working in the correct, intended
> way.
so, find out the intended way and see if you get the right answer
when you try it.
--
brian d foy
CGI Meta FAQ <URL:http://www.smithrenaud.com/public/CGI_MetaFAQ.html>
Perl Mongers <URL:http://www.perl.org/>
------------------------------
Date: Fri, 15 Dec 2000 19:30:05 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: Regex can't be greedy with /(a|ab)/ ?
Message-Id: <x7n1dxh48z.fsf@home.sysarch.com>
>>>>> "AS" == Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> writes:
AS> Well, this type of transform extracts a sort key once per element
AS> and then applies a (usually) trivial comparison routine. This
AS> makes it relatively hard for comparisons to contradict one
AS> another, even if key extraction suffers from side-effects (and
AS> might extract a different key each time).
heh, i know how the ST and GRT work (i am the G of GRT :). but key
extraction is different from actual sorting. if the sort compare
function is not deterministic (like some rand thingy) and the sort code
is not well written, it could crash or run forever. this is what happens
with perl < 5.6. you can still do a sort key extraction and use a bad
comparison function. the GRT eliminates the user level comparison
function altogether so that problem would go away. the ST keeps it but
simplifies it by doing key extraction in advance.
uri
--
Uri Guttman --------- uri@sysarch.com ---------- http://www.sysarch.com
SYStems ARCHitecture, Software Engineering, Perl, Internet, UNIX Consulting
The Perl Books Page ----------- http://www.sysarch.com/cgi-bin/perl_books
The Best Search Engine on the Net ---------- http://www.northernlight.com
------------------------------
Date: 15 Dec 2000 12:47:24 -0600
From: Ren Maddox <ren.maddox@tivoli.com>
Subject: Re: Regex can't be greedy with /(a|ab)/ ?
Message-Id: <m3bsuda5dv.fsf@dhcp11-177.support.tivoli.com>
Uri Guttman <uri@sysarch.com> writes:
> >>>>> "AS" == Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> writes:
>
> AS> On the other hand, this sort of thing can happen inadvertently if
> AS> the sort function has side effects that influence the next outcome.
> AS> BTW, a Schwartz (or similar) transform is a life insurance against
> AS> a this type of sort segfault because the sort function is only called
> AS> once per list element.
>
> huh? assuming an O( N * log N ) sort (like quicksort on average) then
> the sort function is called N * log N times. and it is called on pairs
> of elements so you can't tell (without checking inside the sort
> function) how often it is called per element.
I believe Anno's point was that if you use a ST (or GRT) and move the
questionable operation out of the sort, then the questionable
operation will only be performed once per element. Naturally, the
sort comparison will be performed multiple times per element, but
after one of the transforms, it will presumably be a simple
comparison.
--
Ren Maddox
ren@tivoli.com
------------------------------
Date: Fri, 15 Dec 2000 22:52:29 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: Regex can't be greedy with /(a|ab)/ ?
Message-Id: <x7k891guvm.fsf@home.sysarch.com>
>>>>> "RM" == Ren Maddox <ren.maddox@tivoli.com> writes:
RM> Uri Guttman <uri@sysarch.com> writes:
>> >>>>> "AS" == Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> writes:
>>
AS> On the other hand, this sort of thing can happen inadvertently if
AS> the sort function has side effects that influence the next outcome.
AS> BTW, a Schwartz (or similar) transform is a life insurance against
AS> a this type of sort segfault because the sort function is only called
AS> once per list element.
>>
>> huh? assuming an O( N * log N ) sort (like quicksort on average) then
>> the sort function is called N * log N times. and it is called on pairs
>> of elements so you can't tell (without checking inside the sort
>> function) how often it is called per element.
RM> I believe Anno's point was that if you use a ST (or GRT) and move the
RM> questionable operation out of the sort, then the questionable
RM> operation will only be performed once per element. Naturally, the
RM> sort comparison will be performed multiple times per element, but
RM> after one of the transforms, it will presumably be a simple
RM> comparison.
that wasn't clear to me. if you use a rand key extraction of course the
ST or GRT will sort (sort of) ok. the question was only if the actual
sort function was random or inconsistant. and it was known to crash in
perl < 5.6 which was a major reason to switch to perl's own qsort
instead of standard unix (or whatever) qsort.
uri
--
Uri Guttman --------- uri@sysarch.com ---------- http://www.sysarch.com
SYStems ARCHitecture, Software Engineering, Perl, Internet, UNIX Consulting
The Perl Books Page ----------- http://www.sysarch.com/cgi-bin/perl_books
The Best Search Engine on the Net ---------- http://www.northernlight.com
------------------------------
Date: Fri, 15 Dec 2000 23:02:47 GMT
From: "Jonathan Swartz" <jswartz@sentiat.com>
Subject: Regular Expression Help
Message-Id: <rqx_5.10811$h67.709356@newsread1.prod.itd.earthlink.net>
Hey all,
I'm having some problems with a regular expression that I am attempting to
write. The problem seems simple, and I'm sure I'm just overlooking
something.
Given a link like such..
<a name='lnkTest' href='http://www.mysite.com/' class='link'><font
color='#990000'>Test Link</font></a>
I need to pull just the value from the href property out. For some reason,
my expression bombs when a tag is nested inside of the link. My expression
is as follows...
\s*<a.*\bhref=(.+)>[< ].+
Any help would be greatly appreciated!
Thanks,
Jonathan
jswartz@sentiat.com
------------------------------
Date: Fri, 15 Dec 2000 15:50:34 -0500
From: "Nicholas C. Cheung" <ncheung@draper.com>
Subject: Rewriting a script to make so it can run in background...
Message-Id: <3A3A841A.6DA65078@draper.com>
I have written a script which tests servers every 10 minutes until it is
stopped by giving a stop signal to the program to see if they are up or
down.
The only snag is that it must be able to run in background mode and the
code enclosed below will not run in background mode...
Is there a way to rewrite the code to make it do the same thing but make
it also run in background?
Response from UNIX terminal below:
[me@epsilon /me/perl/scripts]$ this_script.pl &
[2] 1288
[me@epsilon /me/perl/scripts]$
[2]+ Stopped this_script.pl
[me@epsilon /me/perl/scripts]$
Code segment in question causing the problem:
my (@servers) =
("alpha","beta","gamma","delta","epsilon","zeta","eta","iota","kappa","lambda");
my ($num_bad_servers) = 0;
my ($on) = 1;
while ($on != 0) {
foreach (@servers) {
$this_server = $_;
eval {
local $SIG{ALRM} = sub {
for (qw(HUP INT QUIT TERM KILL)) {
kill($_, $rsh_process_pid);
sleep 1;
unless (kill(0, $rsh_process_id)) {
last;
}
}
close RSH;
$num_bad_servers++;
push (@down, $this_server);
die "Operation timed out";
};
alarm 45;
$rsh_process_id = open RSH, "rsh $this_server uptime |";
while (<RSH>) {
chomp ($output = $_);
}
close RSH;
alarm 0;
};
}
sleep 600;
}
Thanks for any and all help!
Nick
------------------------------
Date: Fri, 15 Dec 2000 21:02:39 GMT
From: rzilavec@tcn.net (Richard Zilavec)
Subject: Re: Rewriting a script to make so it can run in background...
Message-Id: <3a3e8687.269523336@news.tcn.net>
> $rsh_process_id = open RSH, "rsh $this_server uptime |";
rsh doesn't like running is the background on some machine, check the
man page. On bsdi, you must do rsh -n....
--
Richard Zilavec
rzilavec@tcn.net
------------------------------
Date: 15 Dec 2000 19:24:30 GMT
From: fuzzybear@pocketmail.com (Ben Okopnik)
Subject: Re: Splitting on more than one character
Message-Id: <slrn93ks2o.b0l.fuzzybear@Odin.Thor>
The ancient archives of 15 Dec 2000 11:06:48 -0700 showed
Tom Christiansen of comp.lang.perl.misc speaking thus:
>In article <slrn93kmu1.ank.fuzzybear@Odin.Thor>,
>Ben Okopnik <fuzzybear@pocketmail.com> wrote:
>>I'm having a problem with splitting a string that has the following form:
>>
>>"This is part1" (Here is part2) [And this is part3]
>>
>>The first part will always be present. The second and the third parts may
>>or may not be (column-delimited data). I need to split this into variables
>>$a, $b, and $c.
>>
>>Here's what I've tried, with lots of variations:
>>
>>($a, $b, $c) = split /("\(\)\[\])/;
>>($a, $b, $c) = split /"|\(|\)|\[|\]/;
>>
>>etc. The typical result is
>>
>>$a=''
>>$b='"'
>>$c='This'
>>
>>I've RTFMd. <sigh> I find that particular perldoc as clear as mud; *no*
>>help. Advice, including solutions that don't use split, would be greatly
>>appreciated.
>
> $_ = q("This is part1" (Here is part2) [And this is part3]);
> ($a) = / " ( [^"]* ) " /x;
> ($b) = / \( ( [^(]* ) \) /x;
> ($c) = / \[ ( [^[]* ) \] /x;
>
> print "a=$a\n";
> print "b=$b\n";
> print "c=$c\n";
>
>To produce:
>
> a=This is part1
> b=Here is part2
> c=And this is part3
>
>--tom
Thanks very much, Tom! It worked perfectly. Now I can get all this stuff
into my database...
Ben Okopnik
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- "Sergeant, what should I do should I happen to unexpectedly encounter
a land mine?" - "Well, sir, normal procedure is to jump two hundred feet
into the air and scatter oneself over a wide area."
------------------------------
Date: 15 Dec 2000 12:55:46 -0600
From: Ren Maddox <ren.maddox@tivoli.com>
Subject: Re: Splitting on more than one character
Message-Id: <m37l51a4zx.fsf@dhcp11-177.support.tivoli.com>
fuzzybear@pocketmail.com (Ben Okopnik) writes:
> I'm having a problem with splitting a string that has the following form:
>
> "This is part1" (Here is part2) [And this is part3]
>
> The first part will always be present. The second and the third parts may
> or may not be (column-delimited data). I need to split this into variables
> $a, $b, and $c.
This is a case where a regex is likely going to be better than using
split.
($a, $b, $c) = /"(.*?)"\s*(\(.*?\))?\s*(\[.*?\])?/;
You may also want to anchor this at the ends.
--
Ren Maddox
ren@tivoli.com
------------------------------
Date: 15 Dec 2000 14:18:14 -0600
From: John Hunter <jdhunter@nitace.bsd.uchicago.edu>
Subject: Re: stripping info, transposing info
Message-Id: <1rg0jpv3p5.fsf@video.bsd.uchicago.edu>
>>>>> "Brian" == Brian E Seppanen <seppy@chartermi.net> writes:
Brian> I'm trying to write a script that will check users quota's.
Brian> Right now, I'm thinking that I can do this by taking du
Brian> --max-depth=1, and putting that into a hash. One issue is
Brian> that du --max-depth=1 returns the following data
Pipe the output of the du command into this script:
Does this do what you want?
John Hunter
#!/usr/local/bin/perl -w
use strict;
my %duout;
while (<>) {
$duout{$2} = $1 if m#(\d+)\s+\./(.*)$#;
}
foreach my $dir (keys %duout) {
print "dir: $dir\tsize: $duout{$dir}\n";
}
------------------------------
Date: Fri, 15 Dec 2000 19:51:58 +0000
From: jb <jb@yperite.demon.co.uk>
Subject: Re: Stripping out meta tags from web pages
Message-Id: <3A3A765E.EABE8D37@yperite.demon.co.uk>
Rafael Garcia-Suarez wrote:
>
> Tony O Sullivan wrote in comp.lang.perl.misc:
> > Hi,
> > Sorry if this is a bit too simple a thing to be asking , just I have spent
> > the last few days on it and I can't find the solution anywhere on the net or
> > think my way round the problem
> >
> > here it is:
> > I am trying to strip out the keywords, descriptions and authors from html
> > documents
>
> You should look at the HTML::Parser module, available from CPAN.
I agree and look at the simpler HTML::TokeParser too
------------------------------
Date: Fri, 15 Dec 2000 15:01:45 -0800
From: Ed Kulis <ekulis@apple.com>
Subject: Re: Total Beginner
Message-Id: <3A3AA2D9.A1AE8B2@apple.com>
Sandra Pearce wrote:
> Hi,
>
> Any good sites for a total beginner to perl....
> I want to create some CGI scripts.
#
# $Id: FAQ_Perl.References.txt,v 1.1.1.2 2000/10/31 20:26:44 ekulis Exp
ekulis $
# SourceServer: tod.apple.com
# $Source: /home/ekulis/Faq/RCS/FAQ_Perl.References.txt,v $
#
return # never execute documentation
Where can I find Perl documentation?
------------------------------------
Web pages and books are legion.
What some URL's to perl Web pages?
----------------------------------
O'Reilly
--------
O'Reilly maintains a perl web page:
http://www.perl.com/pub
where there is extensive documentation at the link
->Downloads
http://www.perl.com/pub/v/documentation
In addtion to general information on topics such as
Perl Syntax, Subroutines, Regular Expressions, Perl Style Guide
there are also very useful pages for
Perl's Builtin Functions
http://www.perl.com/pub/doc/manual/html/pod/perlfunc.html
and
Perl Modules
http://www.perl.com/pub/doc/manual/html/pod/perlmod.html
You might find it convenient to bookmark the functions and the modules
separately.
PerlDoc
-------
Here's another page with a different organization.
http://www.perldoc.com/
Engelschall
-----------
Here's a site of a perl guru with a very nice splash page:
http://www.engelschall.com/title/
that has a very readable list of Perl Modules at
->Next-> Archive-> PerlDoc
http://www.engelschall.com/ar/perldoc/
What are some books on Perl?
----------------------------
O'Reilly has a number of titles.
Perl 5 Pocket Reference by Vromans
--------------------------------------
A quick reference guide.
Learning Perl by Schwartz and Christiansen
--------------------------------------------
Great tutorial introduction.
Scripts avaliable at:
ftp://ftp.oreilly.com/pub/examples/nutshell/learning_perl
Programming Perl by Wall, Christiansen, and Schwartz
-------------------------------------------------------
Less a tutorial, more a manual, more complete.
Doesn't contain all the modules you'll find on the web sites.
Scripts available at:
ftp://ftp.oreilly.com/pub/examples/nutshell/programming_perl
Perl Cookbook by Christiansen and Torkington
----------------------------------------------
What ever you need to do in perl someone has probably done it
before!
Scripts available at:
http://www.oreilly.com/catalog/cookbook -> Examples
ftp://ftp.oreilly.com/published/oreilly/perl/cookbook/
Programming the Perl DBI by Descartes and Bunce
--------------------------------------------------
The Perl DBI provides direct communication between perl and
databases
like Oracle, Informix, Ingres, mysql ...
This eliminates the need for sqlplus and provides complete
access
to the database with loops, conditionals, arrays, reports, etc.
Scripts available at:
http://www.oreilly.com/catalog/perldbi/ -> Examples
ftp://ftp.ora.com/published/oreilly/perl/perldbi/
------------------------------
Date: Fri, 15 Dec 2000 15:16:10 -0500
From: "Vladimir Silyaev" <cbah@chez.com>
Subject: Re: Truncate A Log File
Message-Id: <91du3o$e0k$1@slb6.atl.mindspring.net>
"spurcell" <skpurcell@hotmail.com> wrote in message
news:3a3a5a9d$0$14653@wodc7nh6.news.uu.net...
> Hello,
> I have a log file (I am on a NT box), and I just had noticed that it is
> getting rather large. The scripts is one that runs 7 days a week 24 hours
a
> day. Anyway, I have been told I only need to keep about 500 lines of
> logfiles so I was wondering what may be the best way to truncate a log
file.
> I can open the logfile and read it, but I don't know whether to use a perl
> Truncate function or substr?
>
> Could someone possibly give me guidance.
From the perlfunc(1):
truncate FILEHANDLE,LENGTH
truncate EXPR,LENGTH
Truncates the file opened on FILEHANDLE, or named
by EXPR, to the specified length. Produces a
fatal error if truncate isn't implemented on your
system. Returns TRUE if successful, the undefined
value otherwise.
On M$ DOS like systems you can try close and reopen file with '>' prefix, it
will truncate it to zero length.
--
Vladimir Silyaev
Brainbench MVP for Perl
http://www.brainbench.com
------------------------------
Date: Fri, 15 Dec 2000 22:48:28 GMT
From: Bart Lateur <bart.lateur@skynet.be>
Subject: Re: Truncate A Log File
Message-Id: <0g7l3tcrmoni0b6cmmarr1kk3k26hh388q@4ax.com>
spurcell wrote:
>I have a log file (I am on a NT box), and I just had noticed that it is
>getting rather large. The scripts is one that runs 7 days a week 24 hours a
>day. Anyway, I have been told I only need to keep about 500 lines of
>logfiles so I was wondering what may be the best way to truncate a log file.
>I can open the logfile and read it, but I don't know whether to use a perl
The lines you would be interested in, would be the last lines.
Truncating a logfile just like that, is silly.
Before your log gets too big, rename it. Chances are that the process
will create a new file, with the old name, for new data. This likely
won't work on Unixy systems, because these tend to keep a file open all
the time, and the program would still write to the renamed file until it
gets restarted or otherwise be told to restart from frash (using kill
-HUP, for example). But, I digress. I don't expect this to be the case
on NT.
You may keep the old backups for a while, until you get too many of
them, after which you may loose the oldest files.
There must be some modules around that can to this for you, even
compress the old files. I forgot the name, but I'd look for something
with then ame "rotate". Ah, yes, there it is. Logfile::Rotoate, on CPAN.
Aimed at Unix only, it seems.
--
Bart.
------------------------------
Date: Fri, 15 Dec 2000 15:41:34 -0500
From: "Vladimir Silyaev" <cbah@chez.com>
Subject: Re: using PERL for process automation
Message-Id: <91dvmf$r6k$1@slb7.atl.mindspring.net>
<rrknight@usgs.gov> wrote in message news:91dmm9$7rf$2@qvarsx.er.usgs.gov...
> I am slowly learning PERL, slowly. I am trying to use the script below to
> execute a program from the command prompt. Once the program has been
> executed it waits for input from the user, which I am trying to get the
> PERL script to do for me. The script gets the pprogram going to the point
> that it is waiting for the input (location of file in this case), but then
> does nothing. Can someone give me some guidance on how to get PERL to do
> this, to provide the input that the command porompt is waiting for. It
> just doesn't seem to want to do anything after the program has been
> executed.
>
> chomp ($name = <>); # name is the path name to the input file
> print $name;
> use Win32::Process;
> Win32::Process::Create($ProcessObj,
> "F:\\data\\hspf11.0\\bin\\hspf.bat",
> "hspf $name",
> 1,
> CREATE_NEW_CONSOLE,
> ".") || die "dead";
>
You have a wrong platform and you choose a wrong tool also.
On a right platforms you can to use expect package for functionality you are
looking for.
Regards,
Vladimir
------------------------------
Date: Fri, 15 Dec 2000 19:52:35 -0000
From: cberry@cinenet.net (Craig Berry)
Subject: Re: Why are multiple zeroes true?
Message-Id: <t3ktk363jt3d27@corp.supernews.com>
miko@idocs.com wrote:
: Here's something I've been curious about for some time. Why does Perl
: consider a string of zeroes true? Personally, I find this
: Not-What-I-Expect.
The best way I've ever found to understand Perl falseness is to start with
"undef is false". Then extend this to "the string value of undef (that
is, the empty string) is false", and "the integer value of undef (that is,
0) is false". Finally, "the string value of the integer value of undef
(that is, '0') is false". If you view false values as productions from
undef, the whole thing makes sense. At least to me.
--
| Craig Berry - http://www.cinenet.net/~cberry/
--*-- "The hills are burning, and the wind is raging; and the clock
| strikes midnight in the Garden of Allah." - Don Henley
------------------------------
Date: 15 Dec 2000 21:28:42 GMT
From: Ilmari Karonen <iltzu@sci.invalid>
Subject: Re: Why are multiple zeroes true?
Message-Id: <976915240.4420@itz.pp.sci.fi>
In article <91btkr$s6u$1@nnrp1.deja.com>, miko@idocs.com wrote:
>Here's something I've been curious about for some time. Why does Perl
>consider a string of zeroes true? Personally, I find this
>Not-What-I-Expect.
The simplest way I've found to explain booleans in Perl, defining
simplicity in terms of the number of separate cases involved, is:
When converted to a string, a false value is either "" or "0".
Stringifying an undefined value gives a warning, which using it in
boolean context does not, but it still yields "". The only reason
for the second case is to consistently let numeric 0 be false. It
could've been otherwise, but then a lot of C programmers would get
quite confused.
--
Ilmari Karonen -- http://www.sci.fi/~iltzu/
"Get real! This is a discussion group, not a helpdesk. You post
something, we discuss its implications. If the discussion happens to
answer a question you've asked, that's incidental." -- nobull in clpm
------------------------------
Date: Fri, 15 Dec 2000 22:53:37 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: Why are multiple zeroes true?
Message-Id: <x7hf45gutq.fsf@home.sysarch.com>
>>>>> "CB" == Craig Berry <cberry@cinenet.net> writes:
CB> miko@idocs.com wrote:
CB> : Here's something I've been curious about for some time. Why does Perl
CB> : consider a string of zeroes true? Personally, I find this
CB> : Not-What-I-Expect.
CB> The best way I've ever found to understand Perl falseness is to
CB> start with "undef is false". Then extend this to "the string
CB> value of undef (that is, the empty string) is false", and "the
CB> integer value of undef (that is, 0) is false". Finally, "the
CB> string value of the integer value of undef (that is, '0') is
CB> false". If you view false values as productions from undef, the
CB> whole thing makes sense. At least to me.
see my longer posts which say the same thing. :)
uri
--
Uri Guttman --------- uri@sysarch.com ---------- http://www.sysarch.com
SYStems ARCHitecture, Software Engineering, Perl, Internet, UNIX Consulting
The Perl Books Page ----------- http://www.sysarch.com/cgi-bin/perl_books
The Best Search Engine on the Net ---------- http://www.northernlight.com
------------------------------
Date: Fri, 15 Dec 2000 19:56:12 +0000
From: jb <jb@yperite.demon.co.uk>
Subject: Re: WIN REGISTRY QUESTION
Message-Id: <3A3A775C.419565F9@yperite.demon.co.uk>
Lourdes Orret wrote:
>
> Hello
>
> I need read from a PERL script values stored in the Registry (Win NT 4.0)
> using
> the C++ TRegistry->WriteTime and TRegistry->WriteDateTime.
>
> I was playing with Win32::TieRegistry, but I need a little help. Any
> comments, suggestions and even code is welcome, thanks everyone in advance
Try comp.lang.perl.modules
------------------------------
Date: Fri, 15 Dec 2000 17:26:11 -0200
From: Alessandro Augusto <Alessandro.Augusto@br.bosch.com>
Subject: Re: Windows cant recognize the original owner
Message-Id: <3A3A7053.9F99A1D8@br.bosch.com>
I want to do that with Perl for Windows.
I am using the module Win32::Perms. Is there any
way to do it with?
Come on Perl Gurus...
Alessandro
Gareth Jones wrote:
> you need a version of chown (change owner) for NT. You can get one at:
> http://wwwthep.physik.uni-mainz.de/~frink/nt.html
>
> >How do I do that on a object (file or folder) that the administrator permissions
> >were removed?
>
> Take ownership, set the permissions the way you want, change ownership
> back.
------------------------------
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 5126
**************************************