Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Perl: porters

[perl #70806] perlbug reports "Message sent" even when it hasn't

 

 

Perl porters RSS feed   Index | Next | Previous | View Threaded


perlbug-followup at perl

Nov 25, 2009, 3:02 AM

Post #1 of 3 (211 views)
Permalink
[perl #70806] perlbug reports "Message sent" even when it hasn't

# New Ticket Created by Tim Bunce
# Please include the string: [perl #70806]
# in the subject line of all future correspondence about this issue.
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=70806 >



This is a bug report for perl from timbo [at] timac,
generated with the help of perlbug 1.39 running under perl 5.11.2.

-----------------------------------------------------------------
[Please describe your issue here]

perlbug doesn't check the return status of Mail::Send and so reports
"Message sent" even if it hasn't:

--- ./utils/perlbug.PL.orig 2009-11-25 10:51:02.000000000 +0000
+++ ./utils/perlbug.PL 2009-11-25 10:51:45.000000000 +0000
@@ -1134,7 +1134,7 @@
open(REP, "<$filename") or die "Couldn't open '$filename': $!\n";
while (<REP>) { print $fh $_ }
close(REP) or die "Error closing $filename: $!";
- $fh->close;
+ $fh->close or die "Error sending mail: $!";

print "\nMessage sent.\n";
}

but that's not enough. On my machine (OS X 10.5.8) it still reports
"Message sent" but no mail has been sent.

I wonder how many bug reports have been lost due to this?

[Please do not change anything below this line]
-----------------------------------------------------------------
---
Flags:
category=core
severity=medium
---
Site configuration information for perl 5.11.2:

Configured by timbo at Sat Nov 21 22:55:20 GMT 2009.

Summary of my perl5 (revision 5 version 11 subversion 2) configuration:

Platform:
osname=darwin, osvers=9.8.0, archname=darwin-2level
uname='darwin timac.local 9.8.0 darwin kernel version 9.8.0: wed jul 15 16:55:01 pdt 2009; root:xnu-1228.15.4~1release_i386 i386 '
config_args='-des -Dusedevel -Dprefix=/usr/local/perl5112'
hint=recommended, useposix=true, d_sigaction=define
useithreads=undef, usemultiplicity=undef
useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
use64bitint=undef, use64bitall=undef, uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler:
cc='cc', ccflags ='-fno-common -DPERL_DARWIN -no-cpp-precomp -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -I/opt/local/include',
optimize='-O3',
cppflags='-no-cpp-precomp -fno-common -DPERL_DARWIN -no-cpp-precomp -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -I/opt/local/include'
ccversion='', gccversion='4.0.1 (Apple Inc. build 5465)', gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=8, prototype=define
Linker and Libraries:
ld='env MACOSX_DEPLOYMENT_TARGET=10.3 cc', ldflags =' -fstack-protector -L/usr/local/lib -L/opt/local/lib'
libpth=/usr/local/lib /opt/local/lib /usr/lib
libs=-lgdbm -ldbm -ldl -lm -lutil -lc
perllibs=-ldl -lm -lutil -lc
libc=/usr/lib/libc.dylib, so=dylib, useshrplib=false, libperl=libperl.a
gnulibc_version=''
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' '
cccdlflags=' ', lddlflags=' -bundle -undefined dynamic_lookup -L/usr/local/lib -L/opt/local/lib -fstack-protector'

Locally applied patches:


---
@INC for perl 5.11.2:
/usr/local/perl5112/lib/site_perl/5.11.2/darwin-2level
/usr/local/perl5112/lib/site_perl/5.11.2
/usr/local/perl5112/lib/5.11.2/darwin-2level
/usr/local/perl5112/lib/5.11.2
.

---
Environment for perl 5.11.2:
DYLD_LIBRARY_PATH=/usr/local/jogl-2.0-macosx-universal/lib::/opt/local/lib/mysql5/mysql:/Users/timbo/perl6/parrot/blib/lib
HOME=/Users/timbo
LANG=en_IE.UTF-8
LANGUAGE (unset)
LC_ALL=en_IE.UTF-8
LD_LIBRARY_PATH (unset)
LOGDIR (unset)
PATH=/usr/local/perl5112/bin:/usr/local/openjdk6-b16-24_apr_2009-r1/bin:/opt/local/lib/postgresql83/bin:/Users/timbo/bin:/usr/local/perl58-i/bin:/usr/local/mysql/bin:/usr/local/bin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin
PERLCRITIC=/Users/timbo/.setdev/perlcriticrc
PERLTIDY=/Users/timbo/.setdev/perltidyrc
PERL_BADLANG (unset)
SHELL=/bin/bash


nick at ccl4

Nov 25, 2009, 12:09 PM

Post #2 of 3 (192 views)
Permalink
Re: [perl #70806] perlbug reports "Message sent" even when it hasn't [In reply to]

On Wed, Nov 25, 2009 at 03:02:24AM -0800, Tim Bunce wrote:

> perlbug doesn't check the return status of Mail::Send and so reports
> "Message sent" even if it hasn't:
>
> --- ./utils/perlbug.PL.orig 2009-11-25 10:51:02.000000000 +0000
> +++ ./utils/perlbug.PL 2009-11-25 10:51:45.000000000 +0000
> @@ -1134,7 +1134,7 @@
> open(REP, "<$filename") or die "Couldn't open '$filename': $!\n";
> while (<REP>) { print $fh $_ }
> close(REP) or die "Error closing $filename: $!";
> - $fh->close;
> + $fh->close or die "Error sending mail: $!";
>
> print "\nMessage sent.\n";
> }
>
> but that's not enough. On my machine (OS X 10.5.8) it still reports
> "Message sent" but no mail has been sent.
>
> I wonder how many bug reports have been lost due to this?

Does Mail::Send "eat" the e-mail? Or does it queue it, but the queue fail
to deliver?

On my machine (10.6.1) /usr/sbin/sendmail happily accepts mail, but it's
rapidly bounced by whichever machine it's attempting to contact, and the
bounce is visible to me in /var/mail/nick

Nicholas Clark


rgs at consttype

Nov 26, 2009, 12:43 AM

Post #3 of 3 (184 views)
Permalink
Re: [perl #70806] perlbug reports "Message sent" even when it hasn't [In reply to]

2009/11/25 Tim Bunce <perlbug-followup [at] perl>:
> perlbug doesn't check the return status of Mail::Send and so reports
> "Message sent" even if it hasn't:
>
> --- ./utils/perlbug.PL.orig     2009-11-25 10:51:02.000000000 +0000
> +++ ./utils/perlbug.PL  2009-11-25 10:51:45.000000000 +0000

Thanks, applied as e90b02b98382872bd43097b9b146a9b00ca3171b

Perl porters RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.