develooper Front page | perl.perl5.porters | Postings from September 2018

[perl #133550] [PATCH] Define also Perl's calloc() macro

From:
perlbug-followup
Date:
September 28, 2018 11:43
Subject:
[perl #133550] [PATCH] Define also Perl's calloc() macro
Message ID:
rt-4.0.24-24812-1538135028-641.133550-75-0@perl.org
# New Ticket Created by   
# Please include the string:  [perl #133550]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=133550 >


Functions malloc(), realloc() and free() are already redefined to
PerlMem_malloc(), PerlMem_realloc() and PerlMem_free(). But calloc() not.

This leads to the problem that memory by calloc() is allocated by system
C library, but freed by Perl's PerlMem_free() which just cause memory
corruptions.



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