didn't someone have a solution to the readonly of constant
problem in perl5? is this going to happen, larry?
--tom
------- start of forwarded message -------
Path: csnews!boulder!csn!symbios.com!southwind.net!news.sprintlink.net!simtel!harbinger.cc.monash.edu.au!mail_gw.fwall.telecom.com.au!cdn_mail.telecom.com.au!sjg
From: sjg@dn.itg.telecom.com.au (Simon J. Gerraty)
Newsgroups: comp.lang.perl.misc
Subject: perl5 vs perl4 problems
Date: 12 Sep 95 05:11:17 GMT
Organization: Telstra
Lines: 35
Message-ID: <sjg.810882677@netboss>
NNTP-Posting-Host: netboss-fddi.dn.itg.telecom.com.au
I'm having lots of fun trying to get req to work with perl-5.
It basically uses a setuid C wrapper to run a perl script.
The following snipet works fine with perl4 and perl5 when just run
from the command line - no setuid.
sub append_additions {
for $line (@_) {
$line =~ s:\n*$::;
print "$line\n";
}
}
When run under sendmail, with perl5 I get the error:
Modification of a read-only value attempted at /usr/local/req/etc/req-operation line 1404.
which corresponds to the line:
$line =~ s:\n*$::;
changing that to
$line =~ s:\n*\$::;
allows the command to run successfully, but the newlines are obviously not
removed as intended.
It must be possible to fix this, but I can't even reproduce it without the
help of sendmail and the C wrapper.
--sjg
--
Simon J. Gerraty <sjg@telstra.com.au>
#include <disclaimer> /* imagine something _very_ witty here */
------- end of forwarded message -------
--
Tom Christiansen Perl Consultant, Gamer, Hiker tchrist@mox.perl.com
I have a different view of the world. --Andrew Hume. Show&Tell '87
problem in perl5? is this going to happen, larry?
--tom
------- start of forwarded message -------
Path: csnews!boulder!csn!symbios.com!southwind.net!news.sprintlink.net!simtel!harbinger.cc.monash.edu.au!mail_gw.fwall.telecom.com.au!cdn_mail.telecom.com.au!sjg
From: sjg@dn.itg.telecom.com.au (Simon J. Gerraty)
Newsgroups: comp.lang.perl.misc
Subject: perl5 vs perl4 problems
Date: 12 Sep 95 05:11:17 GMT
Organization: Telstra
Lines: 35
Message-ID: <sjg.810882677@netboss>
NNTP-Posting-Host: netboss-fddi.dn.itg.telecom.com.au
I'm having lots of fun trying to get req to work with perl-5.
It basically uses a setuid C wrapper to run a perl script.
The following snipet works fine with perl4 and perl5 when just run
from the command line - no setuid.
sub append_additions {
for $line (@_) {
$line =~ s:\n*$::;
print "$line\n";
}
}
When run under sendmail, with perl5 I get the error:
Modification of a read-only value attempted at /usr/local/req/etc/req-operation line 1404.
which corresponds to the line:
$line =~ s:\n*$::;
changing that to
$line =~ s:\n*\$::;
allows the command to run successfully, but the newlines are obviously not
removed as intended.
It must be possible to fix this, but I can't even reproduce it without the
help of sendmail and the C wrapper.
--sjg
--
Simon J. Gerraty <sjg@telstra.com.au>
#include <disclaimer> /* imagine something _very_ witty here */
------- end of forwarded message -------
--
Tom Christiansen Perl Consultant, Gamer, Hiker tchrist@mox.perl.com
I have a different view of the world. --Andrew Hume. Show&Tell '87