[23222] in Perl-Users-Digest
Perl-Users Digest, Issue: 5443 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Sep 4 18:10:40 2003
Date: Thu, 4 Sep 2003 15:10: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 Thu, 4 Sep 2003 Volume: 10 Number: 5443
Today's topics:
Re: Spammers LUV SpamAssassin <emurphy42@socal.rr.com>
Re: Spammers LUV SpamAssassin <emschwar@pobox.com>
Re: Spammers LUV SpamAssassin <alanconnor@earthlink.net>
Re: Spammers LUV SpamAssassin <emschwar@pobox.com>
Re: Spammers LUV SpamAssassin <alanconnor@earthlink.net>
Re: Text File Processing (Sam Holden)
Re: Text File Processing (Tad McClellan)
Re: Text File Processing <postmaster@castleamber.com>
Re: Text File Processing <postmaster@castleamber.com>
Re: View NG with Net::NNTP (Tom)
Re: Why qr// needs /o modifier, or bug in a documentati (Sam Holden)
Re: <bwalton@rochester.rr.com>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 04 Sep 2003 19:11:20 GMT
From: "Ed Murphy" <emurphy42@socal.rr.com>
Subject: Re: Spammers LUV SpamAssassin
Message-Id: <pan.2003.09.04.19.08.48.668436@socal.rr.com>
[Forwarded to comp.lang.perl.misc at Peter Breuer's suggestion]
On Thu, 04 Sep 2003 16:56:25 +0000, Alan Connor wrote:
> Path:
> twister.socal.rr.com!cyclone.socal.rr.com!elnk-pas-nf1!newsfeed.earthlink.n
> et!stamper.news.pas.earthlink.net!newsread3.news.pas.earthlink.net.POSTED!n
> ot-for-mail
> Newsgroups: comp.os.linux.misc,comp.mail.misc,comp.os.linux.networking
> From: Alan Connor <alanconnor@earthlink.net>
> Subject: Re: Spammers LUV SpamAssassin
> References: <slrnbkvnad.3ee.dhbrown@hobbes.dhbrown.net>
> <bir1ko$vds$1@pcls4.std.com>
> <7d84b.2300$Lk5.223@newsread3.news.pas.earthlink.net>
> <slrnbl275s.1bf6.bit-bucket@localhost.config.com>
> <cca4b.2526$Lk5.815@newsread3.news.pas.earthlink.net>
> <bispnl$19i$3@pcls4.std.com>
> <fwq4b.3824$Lk5.3575@newsread3.news.pas.earthlink.net>
> <Xns93E94EE16FE8Fprjpp1516202119@210.49.20.254>
> <slrnbl4s01.1cn.me@Athena.localdomain>
> <QGu4b.4059$Lk5.195@newsread3.news.pas.earthlink.net>
> <bivamh$dhsd6$1@ID-144096.news.uni-berlin.de>
> <gZH4b.4562$Lk5.1261@newsread3.news.pas.earthlink.net>
> <bj11aq$e3f08$2@ID-195719.news.uni-berlin.de>
> <8dU4b.6021$Lk5.3223@newsread3.news.pas.earthlink.net>
> <bj7pc4$g4271$1@ID-106564.news.uni-berlin.de>
> Reply-To: alanconnor@earthlink.net
> User-Agent: slrn/0.9.7.3 (Linux)
> Lines: 55
> Message-ID: <Z8K5b.9448$Lk5.7097@newsread3.news.pas.earthlink.net>
> Date: Thu, 04 Sep 2003 16:56:25 GMT
> NNTP-Posting-Host: 63.187.200.72
> X-Complaints-To: abuse@earthlink.net
> X-Trace: newsread3.news.pas.earthlink.net 1062694585 63.187.200.72 (Thu, 04
> Sep 2003 09:56:25 PDT)
> NNTP-Posting-Date: Thu, 04 Sep 2003 09:56:25 PDT
> Organization: EarthLink Inc. -- http://www.EarthLink.net
> Xref: cyclone.socal.rr.com comp.os.linux.misc:373894 comp.mail.misc:32116
> comp.os.linux.networking:326684
> MIME-Version: 1.0
> Content-Type: text/plain
>
>
> On Thu, 04 Sep 2003 19:31:08 +0300, Timo Voipio <oh_hami@hotmail.com> wrote:
>>
>>
>> Alan Connor wrote:
>>
>>> By-the-way, Alice, elrav1 is just a collection of well-commented shell scripts,
>>> not a bloated binary monstrosity like SA.
>>
>> By-the-way, Alan (in case that's your real name), spamassassin is just a
>> collection of perl scripts and C code.
>>
>>> If you are at all *nix/sh literate, you can easily read it and see for yourself
>>> what is happenning.
>>
>> If you are perl- and/or C-literate, you can easily read it and see for
>> yourself what's happening.
>>
>> -Timo
>>
>
>
> Let's see. How many people are there who can read shell scripts compared
> to those who can read C and Perl?
>
> Also, the C comes compiled, right? For most people it certainly does.
> So they have to make a special effort to get the uncompiled code.
>
> And SA is HUGE compared to my program. And to use perl you have to have the
> massive perl program installed, don't you. Making SA larger by miles.
>
> Everyone has a shell already, don't they?
>
> SA is also far more complex than my program. Much more difficult to use.
>
> Then there's the huge memory footprint of SA/perl, and mine has NONE.
>
> But the real bottom line is, of course:
>
>
> MY PROGRAM *WORKS* AND SA DOESN'T.
>
>
>
> I look forward to your next silly post.
>
>
> Alan C
------------------------------
Date: Thu, 04 Sep 2003 13:10:22 -0600
From: Eric Schwartz <emschwar@pobox.com>
Subject: Re: Spammers LUV SpamAssassin
Message-Id: <etofzjcfjz5.fsf@wormtongue.emschwar>
"Ed Murphy" <emurphy42@socal.rr.com> writes:
> [Forwarded to comp.lang.perl.misc at Peter Breuer's suggestion]
Because we don't have enough trolls already?
No thanks.
-=Eric
--
Come to think of it, there are already a million monkeys on a million
typewriters, and Usenet is NOTHING like Shakespeare.
-- Blair Houghton.
------------------------------
Date: Thu, 04 Sep 2003 20:57:17 GMT
From: Alan Connor <alanconnor@earthlink.net>
Subject: Re: Spammers LUV SpamAssassin
Message-Id: <NGN5b.9620$Lk5.5292@newsread3.news.pas.earthlink.net>
On Thu, 04 Sep 2003 13:10:22 -0600, Eric Schwartz <emschwar@pobox.com> wrote:
>
>
> "Ed Murphy" <emurphy42@socal.rr.com> writes:
>> [Forwarded to comp.lang.perl.misc at Peter Breuer's suggestion]
>
> Because we don't have enough trolls already?
>
> No thanks.
>
> -=Eric
You are very amusing, SPAMMER.
I can fully understand why you are afraid of my program.
As it and its ilk grow in popularity, scum like you are going to have
to get honest jobs.
Too bad :-)
And good work there, giving credence to Peter Breuer, the most killfiled
asshole on the Usenet.
Intelligence is as intelligence does......
Alan C
--
take control of your mailbox ----- elrav1 ----- http://tinyurl.com/l55a
------------------------------
Date: Thu, 04 Sep 2003 15:32:35 -0600
From: Eric Schwartz <emschwar@pobox.com>
Subject: Re: Spammers LUV SpamAssassin
Message-Id: <eto4qzstf2k.fsf@wormtongue.emschwar>
Alan Connor <alanconnor@earthlink.net> writes:
> You are very amusing, SPAMMER.
\|||/
(o o)
,----ooO--(_)-------.
| Please |
| don't feed the |
| TROLLs ! |
} |
| - The Management |
'--------------Ooo--'
|__|__|
|| ||
ooO Ooo JW
-=Eric
--
Come to think of it, there are already a million monkeys on a million
typewriters, and Usenet is NOTHING like Shakespeare.
-- Blair Houghton.
------------------------------
Date: Thu, 04 Sep 2003 21:52:45 GMT
From: Alan Connor <alanconnor@earthlink.net>
Subject: Re: Spammers LUV SpamAssassin
Message-Id: <NuO5b.8810$tw6.6612@newsread4.news.pas.earthlink.net>
On Thu, 04 Sep 2003 15:32:35 -0600, Eric Schwartz <emschwar@pobox.com> wrote:
>
>
> Alan Connor <alanconnor@earthlink.net> writes:
>> You are very amusing, SPAMMER.
>
> \|||/
> (o o)
> ,----ooO--(_)-------.
>| Please |
>| don't feed the |
>| TROLLs ! |
> } |
>| - The Management |
> '--------------Ooo--'
> |__|__|
> || ||
> ooO Ooo JW
>
> -=Eric
If you don't want people like Eric to have access to your mailbox,
try my program.
He and his ilk are driven by its effectiveness to abandon all reasonable
argument and must resort to this sort of infantile tactic, worthy of
of ambulance-chasing lawyers and sleaze-ball politicians and bigots every-
where:
In-other-words, they must abandon all pretense of ethics and try to put
a knife in their opponent's back.
Which is exactly the sort of behaviour one would expect from SPAMMERS.
They care nothing for your rights of privacy and don't care what sort of
filth you children see.
Get them out of your life once and for all.
Here's the bottom line: If you are going to accept anonymous mail, then
you are going to be at the mercy of degenerates like Eric.
Trying to figure out a way to get SOME spam and not other spam is like
trying to stand in the rain and only be hit by tear-shaped drops.
That's the reason Eric and his criminal cohorts love SpamAssassin and its
brethren, because they DON'T WORK.
I can GUARANTEE you that Eric and friends know SA better than YOU ever
will.
Alan C
--
take control of your mailbox ----- elrav1 ----- http://tinyurl.com/l55a
------------------------------
Date: 4 Sep 2003 21:28:42 GMT
From: sholden@flexal.cs.usyd.edu.au (Sam Holden)
Subject: Re: Text File Processing
Message-Id: <slrnblfbk9.as1.sholden@flexal.cs.usyd.edu.au>
On Thu, 04 Sep 2003 17:39:04 +0200,
John Bokma <postmaster@castleamber.com> wrote:
> Tad McClellan wrote:
>
>> John Bokma <postmaster@castleamber.com> wrote:
>>
>>
>>>>while ( $buffer = <INPUT> ) {
>>>
>>>IIRC defined($buffer = <INPUT>) ..
>>
>>
>>
>> You do not recall correctly.
>
> What happens if $buffer reads 0 ?
DWIM kicks in and it works (perl adds the defined test).
>
> Has this been changed?
Yes, A long time ago.
--
Sam Holden
------------------------------
Date: Thu, 4 Sep 2003 15:48:32 -0500
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: Text File Processing
Message-Id: <slrnblf990.1up.tadmc@magna.augustmail.com>
John Bokma <postmaster@castleamber.com> wrote:
> Tad McClellan wrote:
>> John Bokma <postmaster@castleamber.com> wrote:
>>
>>
>>>>while ( $buffer = <INPUT> ) {
>>>
>>>IIRC defined($buffer = <INPUT>) ..
>>
>>
>>
>> You do not recall correctly.
>
> What happens if $buffer reads 0 ?
The same thing in either case.
perl will add the defined() test for you if you leave it out:
perl -MO=Deparse -e 'while ( $buffer = <INPUT> ) {1}'
while (defined($buffer = <INPUT>)) {
'???';
}
vs:
perl -MO=Deparse -e 'while ( defined($buffer = <INPUT>) ) {1}'
while (defined($buffer = <INPUT>)) {
'???';
}
> Has this been changed?
Yes. It was changed when the warning for it went away.
I don't remember what version that was at though.
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Thu, 04 Sep 2003 23:49:57 +0200
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Text File Processing
Message-Id: <3f57b3e8$0$192$58c7af7e@news.kabelfoon.nl>
Sam Holden wrote:
> On Thu, 04 Sep 2003 17:39:04 +0200,
> John Bokma <postmaster@castleamber.com> wrote:
>
>>Tad McClellan wrote:
>>
>>
>>>John Bokma <postmaster@castleamber.com> wrote:
>>>
>>>
>>>
>>>>>while ( $buffer = <INPUT> ) {
>>>>
>>>>IIRC defined($buffer = <INPUT>) ..
>>>
>>>
>>>
>>>You do not recall correctly.
>>
>>What happens if $buffer reads 0 ?
>
>
> DWIM kicks in and it works (perl adds the defined test).
Thanks.
>>Has this been changed?
>
> Yes, A long time ago.
Ah, I remember those days some of my scripts broke because of the
defined test missing ('98 or '97).
--
Kind regards, feel free to mail: mail(at)johnbokma.com (or reply)
virtual home: http://johnbokma.com/ ICQ: 218175426
John web site hints: http://johnbokma.com/websitedesign/
------------------------------
Date: Thu, 04 Sep 2003 23:54:22 +0200
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Text File Processing
Message-Id: <3f57b4f2$0$192$58c7af7e@news.kabelfoon.nl>
Tad McClellan wrote:
> Yes. It was changed when the warning for it went away.
Thanks. I remember a server writing an error log that was huge because
of the warning that suddenly popped up in a perl 5.x build. Since then I
always add the defined test.
--
Kind regards, feel free to mail: mail(at)johnbokma.com (or reply)
virtual home: http://johnbokma.com/ ICQ: 218175426
John web site hints: http://johnbokma.com/websitedesign/
------------------------------
Date: 4 Sep 2003 14:09:30 -0700
From: tom@ztml.com (Tom)
Subject: Re: View NG with Net::NNTP
Message-Id: <59b4279a.0309041309.76795c0@posting.google.com>
James Willmore <jwillmore@cyberia.com> wrote in message news:<20030904112427.589720fe.jwillmore@cyberia.com>...
>
> Yes, you're right. :(
>
> Does it work for you (the code I posted)? Anything else in error?
> Comments welcomed.
>
#!/usr/bin/perl -w
use strict;
use Net::NNTP;
#set lexical variables
my($SERVER, $nntp, $articles, $first, $last, $ng_name);
#define NNTP server
$SERVER = 'localhost';
#declare new Net::NNTP object - or die with a connection failure
#message
$nntp = Net::NNTP->new($SERVER, Debug=>0)
or die "Can't connect to server $SERVER: $!\n";
#define what newsgroup to use -
#get the newsgroup name, amount of article, the first article number
#and last article number
($articles,$first,$last,$ng_name) =
$nntp->group('comp.lang.perl.misc');
#print the information out
printf("%s: %5d articles (%-5d to
%-5d)\n",$ng_name,$articles,$first,$last);
#declare a messages counter
my $x = 1;
#set the nntpstat marker to the last message in the newsgroup
#
# ***************
# $nntp->last;
$nntp->nntpstat($last);
# ***************
#while we can go to the next message ....
# ***************
#while($nntp->next){
while(my $msgid=$nntp->last) {
# ***************
#print what number message we're on
print "num: $x\n";
#declare a file handle for the article
# ***************
# not all Net::NNTP packages include this function
# my $fh = $nntp->articlefh;
$nntp->article($msgid,*STDOUT);
# ***************
#print the file handle
# while(<$fh>){
print;
# }
#limit how many messages you want
last if $x == 1;
#increment messages counter
$x++;
}
------------------------------------------
The changes made will output the last (most recent) message first. To
output the oldest message first then nntpstat would be
$nntp->nntpstat($first). The method in the while loop now should be
$nttp->next.
Tom
ztml.com
------------------------------
Date: 4 Sep 2003 21:50:45 GMT
From: sholden@flexal.cs.usyd.edu.au (Sam Holden)
Subject: Re: Why qr// needs /o modifier, or bug in a documentation.
Message-Id: <slrnblfctk.as1.sholden@flexal.cs.usyd.edu.au>
On Thu, 04 Sep 2003 19:51:02 +0400, ddtl <this.is.invalid@yahoo.com> wrote:
>>Just because A -> B, does not mean that !A -> !B.
>>
>>Just because the pattern is compiled once with /o, does not mean that
>>the pattern is not compiled once without /o.
>
> So what that means? Do you mean that when it is said:
>
> "o Compile pattern only once."
>
> means that when you *do not* use 'o', pattern is also compiled only
> once?? If A -> B does not mean that !A -> !B (and what you want to say
> is that when !A there is still B), means that A is not the only reason
> for B. If so, why do you need A at all - it is surely not because
> you want B, because B exists even without A. And that is just rephrasing
> of my question *why* do you need /o???
In this example:
$foo = "foo";
$re = qr/$foo/;
$reo = qr/$foo/o;
for ("foo", "bar") {
$foo = $_;
print "$_ matches re\n" if $_=~/$re/;
print "$_ matches reo\n" if $_=~/$reo/;
}
The regex is compiled once, as evidenced by the non-matching of "bar" when
$foo is changed. This occurs both with and without /o.
qr//o means reevaluation of the qr//o expression won't recompile the
regex (there was previous post pointing this out), for example:
for ("foo", "bar") {
$foo = $_;
$re = qr/$foo/;
$reo = qr/$foo/o;
print "$_ matches re\n" if $_=~/$re/;
print "$_ matches reo\n" if $_=~/$reo/;
}
If you need to do something like that, then you need qr//o.
However, qr// only compiled when qr// is executed, not when the resulting
regex is used. I was interpreting recompiled to mean at the point of usage.
I can't see why if qr//o was wanted, the qr// wouldn't just be moved out of
the loop or function where is was being evaluated and the resulting value
used instead. It seems like more of a compatibility with normal regexes
type feature to me. Of course I am often wrong.
--
Sam Holden
------------------------------
Date: Sat, 19 Jul 2003 01:59:56 GMT
From: Bob Walton <bwalton@rochester.rr.com>
Subject: Re:
Message-Id: <3F18A600.3040306@rochester.rr.com>
Ron wrote:
> Tried this code get a server 500 error.
>
> Anyone know what's wrong with it?
>
> if $DayName eq "Select a Day" or $RouteName eq "Select A Route") {
(---^
> dienice("Please use the back button on your browser to fill out the Day
> & Route fields.");
> }
...
> Ron
...
--
Bob Walton
------------------------------
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.
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 5443
***************************************