[24956] in Perl-Users-Digest
Perl-Users Digest, Issue: 7206 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Oct 4 03:06:48 2004
Date: Mon, 4 Oct 2004 00:05:09 -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 Mon, 4 Oct 2004 Volume: 10 Number: 7206
Today's topics:
Re: Can't compile (perlcc) both Net::FTP and Config::In <usenet@m-me.dk>
Re: Can't compile (perlcc) both Net::FTP and Config::In <kalinaubears@iinet.net.au>
Re: conditional help <matternc@comcast.net>
Re: Custom Perl Scripting <sbryce@scottbryce.com>
Re: Custom Perl Scripting <soon.the.sp@mmers.and.evil.ones.will.bow-down-to.us>
hack out chunk from large text file? (Jason Kinkade)
Re: hack out chunk from large text file? <jurgenex@hotmail.com>
Re: how do i automatically close a Msgbox based on a ti <kalinaubears@iinet.net.au>
How Google/Amazon/eBay use? <aa@bb.cc>
Re: How Google/Amazon/eBay use? <tadmc@augustmail.com>
Re: How Google/Amazon/eBay use? <perl&nntp@rhesa.com>
Re: How Google/Amazon/eBay use? <hexkid@hotpop.com>
Re: How Google/Amazon/eBay use? <perl&nntp@rhesa.com>
Re: How Google/Amazon/eBay use? <jurgenex@hotmail.com>
Re: How Google/Amazon/eBay use? <mlemos@acm.org>
Is HTTPS Proxy Secure? <aa@bb.cc>
Re: Is HTTPS Proxy Secure? <tadmc@augustmail.com>
Re: Is HTTPS Proxy Secure? <aa@bb.cc>
Re: Is HTTPS Proxy Secure? <spamtrap@dot-app.org>
Re: Is PHP still slower than Perl? <postmaster@castleamber.com>
Re: Is PHP still slower than Perl? <postmaster@castleamber.com>
Re: Is PHP still slower than Perl? <postmaster@castleamber.com>
Re: Is PHP still slower than Perl? <postmaster@castleamber.com>
Re: Is PHP still slower than Perl? <blackhole@electrictoolbox.com>
Learn French in the Alps. <i_cute33@hotmail.com>
Re: Perl vs PHP <dformosa@zeta.org.au>
Re: POE HTTP Proxy <troc@pobox.com>
Re: Return top-N of Hashes - hash splice? <matternc@comcast.net>
Two write to a file with flock, what will happen? <aa@bb.cc>
Re: Two write to a file with flock, what will happen? <sholden@flexal.cs.usyd.edu.au>
Re: Two write to a file with flock, what will happen? <spamtrap@dot-app.org>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Sun, 03 Oct 2004 23:53:27 +0100
From: Thomas Watson Steen <usenet@m-me.dk>
Subject: Re: Can't compile (perlcc) both Net::FTP and Config::IniFiles at the same time
Message-Id: <4160830a$0$115$65c69314@mercury.nildram.net>
Sisyphus wrote:
> Thomas Watson Steen wrote:
>
>>
>> Any ideas on how to get arround this?
>>
>
> Yes - use the PAR module's pp utility instead of perlcc.
>
> Cheers,
> Rob
>
Thank you. I'll try pp instead. For the moment I have some problems
doing a make test on pp though, but I hope I can around that one with
some further reseach :)
Thnx again :)
/watson
------------------------------
Date: Mon, 04 Oct 2004 12:21:57 +1000
From: Sisyphus <kalinaubears@iinet.net.au>
Subject: Re: Can't compile (perlcc) both Net::FTP and Config::IniFiles at the same time
Message-Id: <4160b4fe$0$1282$5a62ac22@per-qv1-newsreader-01.iinet.net.au>
Thomas Watson Steen wrote:
> Sisyphus wrote:
>
>> Thomas Watson Steen wrote:
>>
>>>
>>> Any ideas on how to get arround this?
>>>
>>
>> Yes - use the PAR module's pp utility instead of perlcc.
>>
>> Cheers,
>> Rob
>>
>
> Thank you. I'll try pp instead. For the moment I have some problems
> doing a make test on pp though, but I hope I can around that one with
> some further reseach :)
>
> Thnx again :)
>
> /watson
There's a PAR mailing list - which is an excellent source of help (if
you need it). See http://lists.perl.org for details.
Cheers,
Rob
--
To reply by email u have to take out the u in kalinaubears.
------------------------------
Date: Sun, 03 Oct 2004 18:21:38 -0400
From: Chris Mattern <matternc@comcast.net>
Subject: Re: conditional help
Message-Id: <oaOdnbvHeYvp5v3cRVn-pw@comcast.com>
buildmorelines wrote:
> why does this code work?
>
> #!/usr/bin/perl
> print "true" if $ARGV[0];
Because this is valid Perl syntax.
>
> and this doesnt and generates syntax error?
>
> #!/usr/bin/perl
> print "true" if $ARGV[0];
> else print "false";
Because this isn't Perl syntax. You don't get to
make up stuff and tell the interpreter, "You
know what I mean." If you want to use else,
you have to use the compound if statement
with blocks. For one thing, it would be
impossible for the interpreter to correctly
interpret where the else needs to go in nested
if statements if this requirement wasn't
enforced.
--
Christopher Mattern
"Which one you figure tracked us?"
"The ugly one, sir."
"...Could you be more specific?"
------------------------------
Date: Sun, 03 Oct 2004 16:29:11 -0600
From: Scott Bryce <sbryce@scottbryce.com>
Subject: Re: Custom Perl Scripting
Message-Id: <10m0v9kpdvlsk0f@corp.supernews.com>
Perl Newbie wrote:
> I am trying to set up a webpage that uses four frames in a frameset:
Change your page design.
Eliminate the frames, then decide if static or dynamic pages are your
best solution. If dynamic pages are your best solution, then this
becomes a CGI question and it should be asked in a CGI newsgroup.
------------------------------
Date: Sun, 3 Oct 2004 21:03:25 -0400
From: FLEB <soon.the.sp@mmers.and.evil.ones.will.bow-down-to.us>
Subject: Re: Custom Perl Scripting
Message-Id: <48olr2pan06l$.1jlzee4tjapuq.dlg@40tude.net>
Regarding this well-known quote, often attributed to Perl Newbie's famous
"3 Oct 2004 05:21:23 -0700" speech:
> Thanks, I'll look in to Java-based opportunites for my difficulty.
*Javascript*, not Java!
--
-- Rudy Fleminger
-- sp@mmers.and.evil.ones.will.bow-down-to.us
(put "Hey!" in the Subject line for priority processing!)
-- http://www.pixelsaredead.com
------------------------------
Date: 3 Oct 2004 21:21:49 -0700
From: jkinkade@datashelter.net (Jason Kinkade)
Subject: hack out chunk from large text file?
Message-Id: <7aa71c67.0410032021.620691f1@posting.google.com>
I have a text file that looks like.
---unique id---
many lines
---------------
---unique id---
many lines
---------------
---unique id---
many lines
---------------
...etc.
I want to simply remove a section between the ---unique id--- and
---------. Now I know I could go through it line by line and output
the filtered text to a tmp file then copy the tmp file back, but thats
impracticle with the file is like a gig in size. Does anyone know a
way I can operate on the text file directly and remove a section
without copying the whole file to a tmp file or temporatily into
memory?
Thanks
------------------------------
Date: Mon, 04 Oct 2004 04:43:18 GMT
From: "Jürgen Exner" <jurgenex@hotmail.com>
Subject: Re: hack out chunk from large text file?
Message-Id: <Gx48d.4083$eq1.297@trnddc08>
Jason Kinkade wrote:
> I have a text file that looks like.
[...]
> I want to simply remove a section between the ---unique id--- and
Did you check "perldoc -q delete":
How do I change one line in a file/delete a line in a file/insert a
line in the middle of a file/append to the beginning of a file?
jue
------------------------------
Date: Mon, 04 Oct 2004 12:31:26 +1000
From: Sisyphus <kalinaubears@iinet.net.au>
Subject: Re: how do i automatically close a Msgbox based on a timer?
Message-Id: <4160b738$0$1296$5a62ac22@per-qv1-newsreader-01.iinet.net.au>
Dwayne Kuan wrote:
> hi, I'm writing a script that produces a MsgBox but when i do that, i
> notice that control goes to the MsgBox window and the script waits for
> something to happen to that MsgBox before continuing.
>
> is there any way for me to get that script to automatically close that
> msgbox say in 5 seconds?
>
I don't know how/if that can be done. The idea is that a Message Box is
going to tell the user something she/he *needs* to know - and therefore
you want the program to not proceed until the user has acknowledged that
message.
Now, if you're not concerned about the user not seeing this message,
then I recommend that you don't use a Message Box. Simply print() the
message to the screen along, perhaps, with a speaker-beep - if you want
to try to attract the attention of the user.
Cheers,
Rob
--
To reply by email u have to take out the u in kalinaubears.
------------------------------
Date: Sun, 3 Oct 2004 18:09:22 -0400
From: "http://www-free.info" <aa@bb.cc>
Subject: How Google/Amazon/eBay use?
Message-Id: <rvSdnb3DUews5f3cRVn-qA@rogers.com>
As far as I know
Amazon uses Perl
eBay uses C
Google, was not using PHP at
all before late 2003. I bet it is using C.
I am pretty sure that Google does not use database. Not sure about Amazon or
eBay
------------------------------
Date: Sun, 3 Oct 2004 17:49:08 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: How Google/Amazon/eBay use?
Message-Id: <slrncm10f4.g8c.tadmc@magna.augustmail.com>
http://www-free.info <aa@bb.cc> wrote:
> I am pretty sure that Google does not use database.
Wait until the effect of the drugs wears off,
then think about that one some more...
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Mon, 04 Oct 2004 01:02:36 +0200
From: Rhesa Rozendaal <perl&nntp@rhesa.com>
Subject: Re: How Google/Amazon/eBay use?
Message-Id: <4160850d$0$21106$e4fe514c@news.xs4all.nl>
http://www-free.info wrote:
> As far as I know
> Amazon uses Perl
> eBay uses C
> Google, was not using PHP at
> all before late 2003. I bet it is using C.
>
> I am pretty sure that Google does not use database. Not sure about Amazon or
> eBay
No, Google has a reaaallly big hat, from which they pull all the magic
search results. Amazon uses paper napkins when they run out of book margins,
and eBay, well, that's just one big pile of junk really.
Just like a garage sale.
------------------------------
Date: 3 Oct 2004 23:12:07 GMT
From: Pedro Graca <hexkid@hotpop.com>
Subject: Re: How Google/Amazon/eBay use?
Message-Id: <slrncm11q7.vs6.hexkid@ID-203069.user.uni-berlin.de>
Rhesa Rozendaal wrote:
> http://www-free.info wrote:
>> I am pretty sure that Google does not use database. Not sure about Amazon or
>> eBay
>
> No, Google has a reaaallly big hat, from which they pull all the magic
> search results.
Wrong again :)
see for yourself
http://www.google.com/technology/
http://www.google.com/technology/pigeonrank.html
--
USENET would be a better place if everybody read: | to email me: use |
http://www.catb.org/~esr/faqs/smart-questions.html | my name in "To:" |
http://www.netmeister.org/news/learn2quote2.html | header, textonly |
http://www.expita.com/nomime.html | no attachments. |
------------------------------
Date: Mon, 04 Oct 2004 01:55:27 +0200
From: Rhesa Rozendaal <perl&nntp@rhesa.com>
Subject: Re: How Google/Amazon/eBay use?
Message-Id: <41609170$0$568$e4fe514c@news.xs4all.nl>
Pedro Graca wrote:
> Rhesa Rozendaal wrote:
>>http://www-free.info wrote:
>>>I am pretty sure that Google does not use database. Not sure about Amazon or
>>>eBay
>>
>>No, Google has a reaaallly big hat, from which they pull all the magic
>>search results.
>
> Wrong again :)
>
> see for yourself
> http://www.google.com/technology/
> http://www.google.com/technology/pigeonrank.html
>
That's cute!
Google is funnier than I :)
------------------------------
Date: Mon, 04 Oct 2004 04:24:01 GMT
From: "Jürgen Exner" <jurgenex@hotmail.com>
Subject: Re: How Google/Amazon/eBay use?
Message-Id: <Bf48d.4079$eq1.2873@trnddc08>
http://www-free.info wrote:
> I am pretty sure that Google does not use database. Not sure about
> Amazon or eBay
Excuse me?
Where do you think they store their millions of articles/queries/items?
jue
------------------------------
Date: Mon, 04 Oct 2004 02:11:03 -0300
From: Manuel Lemos <mlemos@acm.org>
Subject: Re: How Google/Amazon/eBay use?
Message-Id: <2sc4alF1jcnhaU1@uni-berlin.de>
Hello,
On 10/04/2004 01:24 AM, J=FCrgen Exner wrote:
> http://www-free.info wrote:
>=20
>>I am pretty sure that Google does not use database. Not sure about
>>Amazon or eBay
>=20
>=20
> Excuse me?
> Where do you think they store their millions of articles/queries/items?=
I think he means Google does not use a SQL based database which is=20
something that is known to be true not only about Google but also most=20
search engines.
--=20
Regards,
Manuel Lemos
PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/
PHP Reviews - Reviews of PHP books and other products
http://www.phpclasses.org/reviews/
Metastorage - Data object relational mapping layer generator
http://www.meta-language.net/metastorage.html
------------------------------
Date: Sun, 3 Oct 2004 23:20:09 -0400
From: "http://www-free.info" <aa@bb.cc>
Subject: Is HTTPS Proxy Secure?
Message-Id: <QdqdnUzpIpwUXP3cRVn-pg@rogers.com>
I am trying to access some senstive data on a blocked server, so I am using
proxy on HTTPS port. I think the proxy can cache anything. So I wonder what
kind of cached data it will look like on proxy? Over HTTPS layer, when the
encrption and and decryptiong occur? If a key is passed via proxy as well,
then even the data is encrypted, the proxy with the key can still know what
is going. What is the point of using SSL/HTTPS when the encrypted key is
passed in plain text first?
------------------------------
Date: Sun, 3 Oct 2004 23:26:46 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: Is HTTPS Proxy Secure?
Message-Id: <slrncm1k86.gnj.tadmc@magna.augustmail.com>
http://www-free.info <aa@bb.cc> wrote:
> I am trying to access some senstive data on a blocked server, so I am using
> proxy on HTTPS port. I think the proxy can cache anything. So I wonder what
> kind of cached data it will look like on proxy? Over HTTPS layer, when the
> encrption and and decryptiong occur? If a key is passed via proxy as well,
> then even the data is encrypted, the proxy with the key can still know what
> is going. What is the point of using SSL/HTTPS when the encrypted key is
> passed in plain text first?
What is your Perl question?
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Mon, 4 Oct 2004 01:17:39 -0400
From: "http://www-free.info" <aa@bb.cc>
Subject: Re: Is HTTPS Proxy Secure?
Message-Id: <2vSdnffzBtSOQP3cRVn-og@rogers.com>
> > I am trying to access some senstive data on a blocked server, so I am
using
> > proxy on HTTPS port. I think the proxy can cache anything. So I wonder
what
> > kind of cached data it will look like on proxy? Over HTTPS layer, when
the
> > encrption and and decryptiong occur? If a key is passed via proxy as
well,
> > then even the data is encrypted, the proxy with the key can still know
what
> > is going. What is the point of using SSL/HTTPS when the encrypted key is
> > passed in plain text first?
>
>
> What is your Perl question?
>
I use perl as the download script. If it is not secure, I will think some
other ways to do it. I failed to install my own https proxy.
------------------------------
Date: Mon, 04 Oct 2004 01:49:50 -0400
From: Sherm Pendley <spamtrap@dot-app.org>
Subject: Re: Is HTTPS Proxy Secure?
Message-Id: <eKednTzcR97jef3cRVn-ig@adelphia.com>
http://www-free.info wrote:
> I use perl as the download script.
So what? Your question wasn't about using Perl to write a download
script. Your question was whether this proxy you're using is secure -
and *that* has *nothing* to do with Perl. It's a question about HTTP & SSL.
sherm--
--
Cocoa programming in Perl: http://camelbones.sourceforge.net
Hire me! My resume: http://www.dot-app.org
------------------------------
Date: 4 Oct 2004 04:31:36 GMT
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Is PHP still slower than Perl?
Message-Id: <Xns9577EF4253692castleamber@130.133.1.4>
"Tony Marston" <tony@NOSPAM.demon.co.uk> wrote in news:cjofs2$sa9$1
$830fa795@news.demon.co.uk:
> http://dev.mysql.com/tech-resources/articles/4.1/prepared-statements.html
"Another API that has prepared statement support is PHP. PHP 5 has a new
MySQL interface called "mysqli"."
More cluttering of the namespace :-( Why wasn't this in the language years
(!) ago?
--
John MexIT: http://johnbokma.com/mexit/
personal page: http://johnbokma.com/
Experienced programmer available: http://castleamber.com/
Happy Customers: http://castleamber.com/testimonials.html
------------------------------
Date: 4 Oct 2004 04:32:16 GMT
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Is PHP still slower than Perl?
Message-Id: <Xns9577EF5F72D14castleamber@130.133.1.4>
Tim Tyler <tim@tt1lock.org> wrote in news:I50oKB.rM@bath.ac.uk:
> In comp.lang.php John Bokma <postmaster@castleamber.com> wrote or
> quoted:
>
>> For me Perl is #1 (if possible) because PHP is probably the worst
>> designed language ever.
>
> PHP was never designed. It evolved.
My point ;-)
--
John MexIT: http://johnbokma.com/mexit/
personal page: http://johnbokma.com/
Experienced programmer available: http://castleamber.com/
Happy Customers: http://castleamber.com/testimonials.html
------------------------------
Date: 4 Oct 2004 04:33:51 GMT
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Is PHP still slower than Perl?
Message-Id: <Xns9577EFB526C53castleamber@130.133.1.4>
"Tony Marston" <tony@NOSPAM.demon.co.uk> wrote in
news:cjpei5$hs0$1$830fa17d@news.demon.co.uk:
>
> "Tim Tyler" <tim@tt1lock.org> wrote in message
> news:I50oKB.rM@bath.ac.uk...
>> In comp.lang.php John Bokma <postmaster@castleamber.com> wrote or
>> quoted:
>>
>>> For me Perl is #1 (if possible) because PHP is probably the worst
>>> designed
>>> language ever.
>>
>> PHP was never designed. It evolved.
>
> Most languages evolve for the simple reason that nobody ever gets it
> right the very first time. Ideas change over time, so languages must
> change to keep up with the times.
But it can't hurt to have a good look at how other languages are designed
before you start with the primordial soup (did PHP already reach that
stage?) I mean just reading a few books on general language design could
have given the maker(s) at least some clue.
--
John MexIT: http://johnbokma.com/mexit/
personal page: http://johnbokma.com/
Experienced programmer available: http://castleamber.com/
Happy Customers: http://castleamber.com/testimonials.html
------------------------------
Date: 4 Oct 2004 04:40:44 GMT
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Is PHP still slower than Perl?
Message-Id: <Xns9577F0D8B6D66castleamber@130.133.1.4>
"Michael Vilain <vilain@spamcop.net>" wrote in news:vilain-
6975D5.21011202102004@comcast.dca.giganews.com:
> In article <Xns9576C5FB187DCcastleamber@130.133.1.4>,
> John Bokma <postmaster@castleamber.com> wrote:
>
>> "Tony Marston" <tony@NOSPAM.demon.co.uk> wrote in
>> news:cjmr56$kjq$1$8300dec7@news.demon.co.uk:
>>
>> >
>> > "John Bokma" <postmaster@castleamber.com> wrote in message
>> > news:Xns957679BFC204Bcastleamber@130.133.1.4...
>> >> "@" <asdf@asdfsadf.com> wrote in
>> >> news:hOSdnRvNILPWwsPcRVn-jw@rogers.com:
>> >>
>> >>> A benchmark in 2002 showed PHP is much slower in shell or when
>> >>> Apache has Mod_Perl.
>> >>>
>> >>> With the new PHP kissing Java's ass, Perl is once again the #1
CGI
>> >>> choice.
>> >>
>> >> For me Perl is #1 (if possible) because PHP is probably the worst
>> >> designed language ever. I am not sure if you can already prepare
>> >> statements (MySQL),
>> >
>> > Yes you CAN use prepare statemetnts with MySQL.
>> > You should be aware
>> > that this is a MySQL feature, not a PHP feature.
>>
>> How can I use it from PHP?
>
> Buy one of the many PHP books that mentions building sites and using
> MySQL. O'Reilly has PROGRAMMING PHP, which I used to develop my site.
> There are others, which I leave to you to investigate.
According to the MySQL it just has been evolved into PHP, huray! Version
5 does support it, finally.
[ snip ]
> One thing I like about php is that each script is stored in the usual
> place in the user's document directory. The files are executed and
the
> output is displayed without having to put everything in the
ScriptAlias
> directory (usually cgi-bin).
You can configure Apache to run .cgi from every directory you like, also
you can use mod_rewrite to rewrite your urls.
> While php has PEAR, a depository for additional libraries written by
> others, perl has CPAN which is at least 2 orders of magnitude larger
and
> more diverse.
Only 2? I think it has also been longer around, and quite a few modules
have excellent programmers behind them.
> There's also lots of network and system-level things you
> can do with perl and usually someone's already done it in a CPAN
module.
Agreed.
--
John MexIT: http://johnbokma.com/mexit/
personal page: http://johnbokma.com/
Experienced programmer available: http://castleamber.com/
Happy Customers: http://castleamber.com/testimonials.html
------------------------------
Date: Mon, 04 Oct 2004 17:49:12 +1300
From: Chris Hope <blackhole@electrictoolbox.com>
Subject: Re: Is PHP still slower than Perl?
Message-Id: <3E48d.9683$JQ4.648438@news.xtra.co.nz>
John Bokma wrote:
>> "Tim Tyler" <tim@tt1lock.org> wrote in message
>> news:I50oKB.rM@bath.ac.uk...
>>> In comp.lang.php John Bokma <postmaster@castleamber.com> wrote or
>>> quoted:
>>>
>>>> For me Perl is #1 (if possible) because PHP is probably the worst
>>>> designed
>>>> language ever.
>>>
>>> PHP was never designed. It evolved.
>>
>> Most languages evolve for the simple reason that nobody ever gets it
>> right the very first time. Ideas change over time, so languages must
>> change to keep up with the times.
>
> But it can't hurt to have a good look at how other languages are designed
> before you start with the primordial soup (did PHP already reach that
> stage?) I mean just reading a few books on general language design could
> have given the maker(s) at least some clue.
That may be so, but PHP was initially created as a quick and simple way for
the creator to measure the number of people who viewed his CV online, and
it evolved from there. Interestingly enough, it started off as a collection
of libraries written in Perl, and then moved to an implementation written
in C with version 2.0.
If you are interested, you can read the history at
http://www.php.net/history
--
Chris Hope - The Electric Toolbox - http://www.electrictoolbox.com/
------------------------------
Date: Mon, 4 Oct 2004 00:27:59 +0200
From: John Cuteaux<i_cute33@hotmail.com>
Subject: Learn French in the Alps.
Message-Id: <41607cee$1$25456$8fcfb975@news.wanadoo.fr>
To learn French in France, I found this great school, located both in Annecy and Chambéry, in the heart of the Alps. Given the number of activities and the surroundings I thought I would share this ressource with others.
http://www.ifalpes.com
Let me know if you have any good education portal ressources. Thanks.
------------------------------
Date: 04 Oct 2004 09:20:21 +1000
From: ? the Platypus {aka David Formosa} <dformosa@zeta.org.au>
Subject: Re: Perl vs PHP
Message-Id: <m3hdpbbd8q.fsf@dformosa.zeta.org.au>
Tad McClellan <tadmc@augustmail.com> writes:
> ? the Platypus {aka David Formosa} <dformosa@zeta.org.au> wrote:
[...]
> > A contradiction.
>
>
> David, why are you answering 4-month old posts?
Because I failed to read the date header.
--
Please excuse my spelling as I suffer from agraphia. See
http://dformosa.zeta.org.au/~dformosa/Spelling.html to find out more.
Free the Memes.
------------------------------
Date: Mon, 04 Oct 2004 04:06:39 GMT
From: Rocco Caputo <troc@pobox.com>
Subject: Re: POE HTTP Proxy
Message-Id: <slrncm1j3k.hdf.troc@eyrie.homenet>
On 3 Oct 2004 12:26:30 -0700, George Pabst wrote:
> Hello,
>
> I am working on creating a proxy server based off the example given on
> the poe.perl.org website for a HTTP Proxy.
[...]
You also posted this to POE's mailing list. At leant one response has
already been posted there. In the interest of not duplicating effort,
you should look there for responses.
--
Rocco Caputo - http://poe.perl.org/
------------------------------
Date: Sun, 03 Oct 2004 18:28:01 -0400
From: Chris Mattern <matternc@comcast.net>
Subject: Re: Return top-N of Hashes - hash splice?
Message-Id: <oaOdnbrHeYts4f3cRVn-pw@comcast.com>
Edward Wijaya wrote:
> Hi
>
> With this hashes:
>
> $hash = {
> '1-1' => 3,
> '2-3' => 2,
> '2-2' => 1,
> '1-2' => 6,
> '1-3' => 3
> };
>
> What's the best to retrieve the top-N hashes
> from it. So, with N = 3 it will become:
"Non sequitur. Your facts are uncoordinated."
There is no such thing as "the top-N hashes".
Hashes are unordered. Any attempt to think about
getting the "first" or "top" N elements of hash
will only bring you pain and grief. What are
you actually trying to do?
>
> $hash_top3 = {
> '1-1' => 3,
> '2-3' => 2,
> '2-2' => 1,
> };
>
> Thanks beforehand.
>
> Regards,
> Edward WIJAYA
> SINGAPORE
>
>
--
Christopher Mattern
"Which one you figure tracked us?"
"The ugly one, sir."
"...Could you be more specific?"
------------------------------
Date: Mon, 4 Oct 2004 01:19:56 -0400
From: "http://www-free.info" <aa@bb.cc>
Subject: Two write to a file with flock, what will happen?
Message-Id: <n8mdnQ4osbsBQP3cRVn-oA@rogers.com>
Will the second process wait for the first one to finish?
If so, for how long or how many tries?
------------------------------
Date: 4 Oct 2004 05:30:42 GMT
From: Sam Holden <sholden@flexal.cs.usyd.edu.au>
Subject: Re: Two write to a file with flock, what will happen?
Message-Id: <slrncm1o02.2eo.sholden@flexal.cs.usyd.edu.au>
On Mon, 4 Oct 2004 01:19:56 -0400, http://www-free.info <aa@bb.cc> wrote:
> Will the second process wait for the first one to finish?
>
> If so, for how long or how many tries?
Two processes can not both have an (exclusive) lock on the same file
and hence the situation can't arise.
flock will block until the file becomes available, for as long as
it takes (ie. until all other processes have released their conflicting
locks). So whichever process didn't get the lock first will wait for
the other one to release the lock. Unless you use LOCK_NB.
perldoc -f flock
--
Sam Holden
------------------------------
Date: Mon, 04 Oct 2004 01:36:03 -0400
From: Sherm Pendley <spamtrap@dot-app.org>
Subject: Re: Two write to a file with flock, what will happen?
Message-Id: <ZpOdnRNZCtPefP3cRVn-vA@adelphia.com>
http://www-free.info wrote:
> Will the second process wait for the first one to finish?
>
> If so, for how long or how many tries?
It's considered polite to read the relevant documentation before asking
questions here. In this case, that is:
perldoc -f flock
sherm--
--
Cocoa programming in Perl: http://camelbones.sourceforge.net
Hire me! My resume: http://www.dot-app.org
------------------------------
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 7206
***************************************