Front page | perl.perl5.porters |
Postings from November 2000
November 27, 2000 19:42
Message ID: 20001128034222.C83261B57A@neo.charterpa.net
~s Bug in split with 5.6.0 - Can't find a documented reason for it
This is a bug report for perl from firstname.lastname@example.org,
generated with the help of perlbug 1.28 running under perl v5.6.0.
[Please enter your report here]
Recently (about a week ago) I sent a bug report regarding this issue with more details, but I
didn't use perlbug -- I sent it to the perlbug address manually per the
README. My apologies for being unaware of the desired format. This is a
follow-up to the previous message.
Basically, as best I can tell, perl 5.6.0 introduces a problem in split()
that causes the following line in NeoMail (http://neomail.sourceforge.net)
to no longer work quite properly.
($currentbody, @attachments) = split(/\-\-\Q$boundary\E\n*/,$currentbody);
This line is designed to split a message's attachments based on the attachment
boundary. Pre-5.6.0 versions of perl have no issues with this. The final
element of @attachment, of course, is garbage data, normally, consisting of the
final --\n indicating the last attachment, but is discarded. Perl 5.6.0,
however, returns the entire final boundary information in the last *valid*
element of the array, corrupting the attachment's contents. I have scanned
the source of NeoMail like crazy hunting for something I'm doing wrong, but I
can't find anything in this simple statement that shouldn't cause the split to
function properly and for some reason with 5.6.0 it isn't. I've searched the
CHANGELOGs for documented changes in perl 5.6.0's behavior, and found nothing.
Since I never received a response to my original report, I'm concerned that
perhaps my report was written off as something wrong with my program that isn't
a bug in Perl 5.6.0. Since I scanned the documentation, my source code, and
the same code works with pre-5.6.0, I can't imagine that being the case. Not
that I'm that good a programmer, mind you, just that I don't think the code
fragment is that difficult to debug. :(
As I'm waiting on a possible solution to include in NeoMail or in the docs
regarding what's causing it and an ETA on a fix to release the next version of
my software, if I'm barking up the wrong tree with this problem, please let me
know, so I can go ahead and make my release.
Thanks very much for reading this report. We now return you to your regular programming. ;)
[Please do not change anything below this line]
Site configuration information for perl v5.6.0:
Configured by flepied at Sat Sep 30 18:19:36 CEST 2000.
Summary of my perl5 (revision 5.0 version 6 subversion 0) configuration:
osname=linux, osvers=2.2.17-16mdksmp, archname=i386-linux
uname='linux debris.mandrakesoft.com 2.2.17-16mdksmp #1 smp thu sep 28 15:25:49 cest 2000 i686 unknown '
config_args='-des -Darchname=i386-linux -Dd_dosuid -Ud_csh -Duseshrplib -Doptimize=-O3 -fomit-frame-pointer -pipe -s -march=pentium -ffast-math -fexpensive-optimizations -Dprefix=/usr -Dman1dir=/usr/share/man/man1 -Dman3dir=/usr/lib/perl5/man/man3'
hint=recommended, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef
useperlio=undef d_sfio=undef uselargefiles=define
use64bitint=undef use64bitall=undef uselongdouble=undef usesocks=undef
cc='cc', optimize='-O3 -fomit-frame-pointer -pipe -s -march=pentium -ffast-math -fexpensive-optimizations', gccversion=2.95.3 19991030 (prerelease)
ccflags ='-fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
stdchar='char', d_stdstdio=define, usevfork=false
intsize=4, longsize=4, ptrsize=4, doublesize=8
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=4, usemymalloc=n, prototype=define
Linker and Libraries:
ld='cc', ldflags =' -L/usr/local/lib'
libpth=/usr/local/lib /lib /usr/lib
libs=-lnsl -ldl -lm -lc -lposix -lcrypt
libc=/lib/libc-2.1.3.so, so=so, useshrplib=true, libperl=libperl.so
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-rdynamic -Wl,-rpath,/usr/lib/perl5/5.6.0/i386-linux/CORE'
cccdlflags='-fpic', lddlflags='-shared -L/usr/local/lib'
Locally applied patches:
@INC for perl v5.6.0:
Environment for perl v5.6.0: