timr@gssc.UUCP (Tim Roberts) (01/24/91)
I am encountering what I believe to be a bug in the MS-DOS port of Perl at patch level 41, with header "perly.c,v 3.0.1.9 90/11/10 01:53:26". Before I really dig in to investigate, however, I want to check to see if anyone else has encountered this problem. Occasionally while reading data files, my scripts see repeated or missing characters. It happens during the read; if I put a "print" immediately after the "while (<FILE>) {", I see the bad data. Here is a sample of what I see: Actual data: io16 aee8 = 1111 # This should cause another interrupt My script sees: ioio16 aee8 = 1111 # This should cause another ierrupt It's almost as if a strncpy or memmove were being done in the middle of the input buffer. Has anyone else seen any unexplained character duplications? I have not yet tried to isolate this down to the minimum script necessary to duplicate, but if I don't get any responses, I will do so. -- timr@gssc.gss.com Tim N Roberts, CCP Graphic Software Systems Beaverton, OR Zen Master to hot dog vendor: "Make me one with everything."
vinoski@apollo.HP.COM (Stephen Vinoski) (01/24/91)
In article <6504@gssc.UUCP> timr@gssc.UUCP (Tim Roberts) writes: >I am encountering what I believe to be a bug in the MS-DOS port of Perl at >patch level 41, with header "perly.c,v 3.0.1.9 90/11/10 01:53:26". Before I >really dig in to investigate, however, I want to check to see if anyone else >has encountered this problem. > >Occasionally while reading data files, my scripts see repeated or missing >characters. It happens during the read; if I put a "print" immediately after >the "while (<FILE>) {", I see the bad data. Patchlevel 41 had a bug in str.c which was fixed in pl44. Until you get to pl44, apply the enclosed patch to fix the trouble you're having. *** str.c.old Fri Nov 16 20:23:48 1990 --- str.c Sat Nov 17 12:32:11 1990 *************** *** 804,809 **** --- 804,810 ---- if (get_paragraph && oldbp) obpx = oldbp - str->str_ptr; bpx = bp - str->str_ptr; /* prepare for possible relocation */ + str->str_cur = bpx; STR_GROW(str, str->str_len + append + cnt + 2); bp = str->str_ptr + bpx; /* reconstitute our pointer */ if (get_paragraph && oldbp) -steve | Steve Vinoski (508)256-6600 x5904 | Internet: vinoski@apollo.hp.com | | Testability and Diagnostics | UUCP: ...mit-eddie!apollo!vinoski| | HP Apollo Division, Chelmsford, MA 01824 | ...uw-beaver!apollo!vinoski|