Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-92888: Fix memoryview bad__index__ use after free#92946

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
Fidget-Spinner merged 12 commits intopython:mainfromFidget-Spinner:fix_memoryview_auf
Jun 17, 2022
Merged
Changes from1 commit
Commits
Show all changes
12 commits
Select commitHold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Fix newline
  • Loading branch information
@Fidget-Spinner
Fidget-Spinner committedMay 23, 2022
commit42a706c9597a7e7b06cc4380fef5a742053e083f
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
Fix ``memoryview`` use after free when accessing the backing buffer in certain cases.
Fix ``memoryview`` use after free when accessing the backing buffer in certain cases.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I propose to mention more explicitly that the protection is about released views:

If a memoryview is released while getting or setting an item, raise an exception.For example, converting an object to an index can execute arbitrary Pythoncode which can indirectly release the memoryview.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Not always an exception is raised.

The bug was in reading or wring the freed memory. Now it is prevented -- you either get an exception or free the memory after reading.@Fidget-Spinner's description is more correct.

I am going to address such inconsistency in a separate issue.



[8]ページ先頭

©2009-2025 Movatter.jp