develooper Front page | perl.perl5.porters | Postings from August 2009

Re: [perl #68398] [RESOLVED] some bugs in syswrite

Marc Lehmann
August 11, 2009 03:15
Re: [perl #68398] [RESOLVED] some bugs in syswrite
Message ID:
On Tue, Aug 11, 2009 at 03:00:39AM -0700, reneeb via RT <> wrote:
> According to our records, your request regarding 
>   "some bugs in syswrite" 
> has been resolved. 

According to the other rt ticket, half of the problem was addressed, and
the corner conditions have been discussed, but never fixed (I checked
current bleadperl).

So while ticket 67912 discusses both issues, only the first one was actually
resolved, while the discussion for the latter (offset outside string) just
died off after zefram gave the correct list of conditions.

bleadperl still has the weird and bogus:

            } else if (offset >= (IV)blen_chars && blen_chars > 0) {

condition which looks like an off-by-one bug. It should really be:

            } else if (offset > (IV)blen_chars) {

as offset n is valid in an n-char string (at least substr etc. have no
issue with it).

                The choice of a       Deliantra, the free code+content MORPG
      -----==-     _GNU_    
      ----==-- _       generation
      ---==---(_)__  __ ____  __      Marc Lehmann
      --==---/ / _ \/ // /\ \/ /
      -=====/_/_//_/\_,_/ /_/\_\ Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About