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

Commit92050e8

Browse files
gh-101967: add a missing error check (GH-101968)
(cherry picked from commit89413bb)Co-authored-by: Eclips4 <80244920+Eclips4@users.noreply.github.com>
1 parent3c1b495 commit92050e8

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix possible segfault in ``positional_only_passed_as_keyword`` function, when new list created.

‎Python/ceval.c‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4718,7 +4718,9 @@ positional_only_passed_as_keyword(PyThreadState *tstate, PyCodeObject *co,
47184718
{
47194719
intposonly_conflicts=0;
47204720
PyObject*posonly_names=PyList_New(0);
4721-
4721+
if (posonly_names==NULL) {
4722+
gotofail;
4723+
}
47224724
for(intk=0;k<co->co_posonlyargcount;k++){
47234725
PyObject*posonly_name=PyTuple_GET_ITEM(co->co_varnames,k);
47244726

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp