develooper Front page | perl.perl5.changes | Postings from February 2021

[Perl/perl5] 553cc1: handy.h: Fix #ifdef

From:
Karl Williamson via perl5-changes
Date:
February 28, 2021 15:14
Subject:
[Perl/perl5] 553cc1: handy.h: Fix #ifdef
Message ID:
Perl/perl5/push/refs/heads/blead/dac497-5f41fa@github.com
  Branch: refs/heads/blead
  Home:   https://github.com/Perl/perl5
  Commit: 553cc101838a8c491686b81e3ac6cc4417c40139
      https://github.com/Perl/perl5/commit/553cc101838a8c491686b81e3ac6cc4417c40139
  Author: Karl Williamson <khw@cpan.org>
  Date:   2021-02-28 (Sun, 28 Feb 2021)

  Changed paths:
    M handy.h

  Log Message:
  -----------
  handy.h: Fix #ifdef

The prior code had a comment that indicated uncertainty about its
correctness.  I found a case where it didn't work, and am changing it
accordingly.  I have more confidence that this is right.


  Commit: 5f41fa466a67b5535aa8bcf4b814f242545ac7bd
      https://github.com/Perl/perl5/commit/5f41fa466a67b5535aa8bcf4b814f242545ac7bd
  Author: Karl Williamson <khw@cpan.org>
  Date:   2021-02-28 (Sun, 28 Feb 2021)

  Changed paths:
    M regcomp.c
    M t/op/svleak.t

  Log Message:
  -----------
  regcomp.c: Remove memory leak

This fixes GH #18604.  There was a path through the code where a
particular SV did not get its reference count decremented.

I did an audit of the function and came up with several other
possiblities that are included in this commit.

Further, there would be leaks for some instances of finding syntax
errors in the input pattern, or when warnings are fatalized.  Those
would require mortalizing some SVs, but that is beyond the scope of this
commit.


Compare: https://github.com/Perl/perl5/compare/dac4979cf4bf...5f41fa466a67



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