develooper Front page | perl.perl5.porters | Postings from March 2000

re: perl 5.6.RC2 pp_sys.c problem (AIX 4.3.3.11)

From:
David R. Favor
Date:
March 15, 2000 07:08
Subject:
re: perl 5.6.RC2 pp_sys.c problem (AIX 4.3.3.11)
Message ID:
38CFA76F.42FC9245@austin.ibm.com
High weirdness abounds... I am totally confused about what is suppose to
be happening here:

When I replace the code in pp_sys.c with the following and run it (outside dbx):

        {
            /* See the note at doio.c:do_print about filesize limits. --jhi */
            int fn = PerlIO_fileno(IoIFP(io));
            Off_t ilen = 1943;
            length = PerlLIO_write(fn, buffer+offset, ilen);
            printf("fn=%d buffer=%X offset=%d isize=%d ilen=%d osize=%d olen=%d\n",
                    fn,    buffer,  offset, sizeof(ilen), ilen, sizeof(length), length);
        }

I get the following output:

   dgsp>cat ~/bin/junker
   #!/rpm/BUILD/perl-5.6.0-RC2/miniperl -I/rpm/BUILD/perl-5.6.0-RC2/lib

   use File::Copy;

   print "pid is $$\n";

   copy('/etc/hosts','/home/dfavor/bin/junk.txt');
   dgsp>~/bin/junker
   pid is 23330
   fn=4 buffer=20035ED8 offset=0 isize=0 ilen=8 osize=0 olen=1943

The fileno is correct, but I'm unsure what I'm seeing for the other values.
It's as if the stack is corrupt and the printf() values are shifted some way.

Suggestions?



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About