◐ Shell
reader mode source ↗
Skip to content

bpo-31626: Fixed a bug in debug memory allocator.#3844

Merged
serhiy-storchaka merged 4 commits into
python:masterfrom
serhiy-storchaka:debug-realloc-deadbytes
Oct 31, 2017
Merged

bpo-31626: Fixed a bug in debug memory allocator.#3844
serhiy-storchaka merged 4 commits into
python:masterfrom
serhiy-storchaka:debug-realloc-deadbytes

Conversation

@serhiy-storchaka

@serhiy-storchaka serhiy-storchaka commented Oct 1, 2017

Copy link
Copy Markdown
Member

There was a write to freed memory after shrinking a memory block.

https://bugs.python.org/issue31626

There was a write to freed memory after shrinking a memory block.
@vstinner

vstinner commented Oct 5, 2017

Copy link
Copy Markdown
Member

I wrote a different fix: #3898 rewrites the debug hook to not call realloc() anymore, but use malloc()+free(), reusing debug hooks for malloc() and free().

@serhiy-storchaka serhiy-storchaka merged commit b484d56 into python:master Oct 31, 2017
@miss-islington

Copy link
Copy Markdown
Contributor

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.6.
🐍🍒⛏🤖

@serhiy-storchaka serhiy-storchaka deleted the debug-realloc-deadbytes branch October 31, 2017 12:05
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 31, 2017
Removed a code that incorrectly detected in-place resizing in realloc()
 and wrote to freed memory.
(cherry picked from commit b484d56)
@bedevere-bot

Copy link
Copy Markdown

GH-4191 is a backport of this pull request to the 3.6 branch.

serhiy-storchaka pushed a commit that referenced this pull request Oct 31, 2017
Removed a code that incorrectly detected in-place resizing in realloc()
 and wrote to freed memory.
(cherry picked from commit b484d56)
embray pushed a commit to embray/cpython that referenced this pull request Nov 9, 2017
Removed a code that incorrectly detected in-place resizing in realloc()
 and wrote to freed memory.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type-bug An unexpected behavior, bug, or error

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants