Skip to content
Snippets Groups Projects
Select Git revision
  • master default protected
1 result

objarray.c

  • Damien George's avatar
    acfbb9fe
    py/objarray: Fix amount of free space in array when doing slice assign. · acfbb9fe
    Damien George authored
    Prior to this patch the amount of free space in an array (including
    bytearray) was not being maintained correctly for the case of slice
    assignment which changed the size of the array.  Under certain cases (as
    encoded in the new test) it was possible that the array could grow beyond
    its allocated memory block and corrupt the heap.
    
    Fixes issue #4127.
    acfbb9fe
    History
    py/objarray: Fix amount of free space in array when doing slice assign.
    Damien George authored
    Prior to this patch the amount of free space in an array (including
    bytearray) was not being maintained correctly for the case of slice
    assignment which changed the size of the array.  Under certain cases (as
    encoded in the new test) it was possible that the array could grow beyond
    its allocated memory block and corrupt the heap.
    
    Fixes issue #4127.