In perl.git, the branch smoke-me/nicholas/rt-65838-fixup has been created

<http://perl5.git.perl.org/perl.git/commitdiff/4ce8df50a8b3fb38a4572de816078cb3f5089ff5?hp=0000000000000000000000000000000000000000>

        at  4ce8df50a8b3fb38a4572de816078cb3f5089ff5 (commit)

- Log -----------------------------------------------------------------
commit 4ce8df50a8b3fb38a4572de816078cb3f5089ff5
Author: Nicholas Clark <n...@ccl4.org>
Date:   Thu Jun 27 18:09:32 2013 +0200

    Avoid read-after-free in S_scan_heredoc() if the terminator line has no 
"\n".
    
    The code added by commit 112d128413206514 to fix RT #65838 (Allow here-doc
    with no final newline) could in some rare cases cause a read of free()d
    memory during parsing. The code itself is only run if the Perl program
    ends with a heredoc (which is an unusual structure), and if the last line of
    the file on disk has terminating newline character (which is also unusual,
    as many editors default to adding a final newline). The bug would be
    triggered if the fixup code in S_scan_heredoc() triggered a reallocation of
    the buffer in PL_linestr when adding a newline to it.

M       t/op/heredoc.t
M       toke.c

commit cb37e87fe4576a10b7e13317aca490511baee726
Author: Nicholas Clark <n...@ccl4.org>
Date:   Wed Jun 26 18:24:19 2013 +0200

    For -DPERL_GLOBAL_STRUCT, eliminate local variable plvarsp in main().

M       miniperlmain.c

commit 091ec938fce4acb783a3844df00c50263ffa24cd
Author: Nicholas Clark <n...@ccl4.org>
Date:   Wed Jun 26 18:01:09 2013 +0200

    Fix SEGVs and test failures for -DPERL_GLOBAL_STRUCT_PRIVATE
    
    With PERL_GLOBAL_STRUCT_PRIVATE "global" variables are in a structure in
    malloc()ed memory, not in global static variables or a global static
    structure. Hence no global variables are implicitly initialised to zero.
    
    * PL_curinterp, PL_op_sequence and PL_watch_pvx need initialising to NULL.
    * The global structure is free()d before handlers registered with atexit()
      run, so be defensive about this.
    * Some C code checks SvOK(PL_sv_placeholder) so ensure that its SvFLAGS()
      are 0.
    * Zero PL_hash_seed.

M       miniperlmain.c
M       perl.c
M       perlvars.h
M       util.c
-----------------------------------------------------------------------

--
Perl5 Master Repository

Reply via email to