Skip to content

gh-159320: Enable stack size detection on Android - #159321

Merged
Yhg1s merged 3 commits into
python:mainfrom
Yhg1s:android-stack-check
Oct 14, 2026
Merged

Yhg1s merged 3 commits into
python:mainfrom
Yhg1s:android-stack-check

Conversation

@Yhg1s

@Yhg1s Yhg1s commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

Extend the use of pthread_getattr_np in stack size detection from any glibc linux to any glibc or android linux, instead of assuming a minimum size of 1.2Mb (which we override in tests).

… glibc

linux to any glibc *or* android linux.
@Yhg1s

Yhg1s commented Oct 13, 2026

Copy link
Copy Markdown
Member Author

#159376 is a more general fix for the same issue (instead of just Android it enables stack protection on all Linux libc's)

@mhsmith mhsmith left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, but I guess it would be better to merge #159376 instead.

Comment thread Python/ceval.c Resolved
Co-authored-by: Malcolm Smith <smith@chaquo.com>
@Yhg1s

Yhg1s commented Oct 14, 2026

Copy link
Copy Markdown
Member Author

LGTM, but I guess it would be better to merge #159376 instead.

Actually, after some consideration I think we should merge this and backport it, then merge the other one for 3.16+ only.

@Yhg1s
Yhg1s enabled auto-merge (squash) October 14, 2026 11:37
@Yhg1s Yhg1s added needs backport to 3.14 bugs and security fixes needs backport to 3.15 bugs and security fixes labels Oct 14, 2026
@Yhg1s
Yhg1s disabled auto-merge October 14, 2026 12:10
@Yhg1s
Yhg1s merged commit 8ff41c2 into python:main Oct 14, 2026
65 checks passed
@miss-islington-app

Copy link
Copy Markdown

Thanks @Yhg1s for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15.
🐍🍒⛏🤖

@bedevere-app

bedevere-app Bot commented Oct 14, 2026

Copy link
Copy Markdown

GH-159409 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Oct 14, 2026
@bedevere-app

bedevere-app Bot commented Oct 14, 2026

Copy link
Copy Markdown

GH-159410 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Oct 14, 2026
Yhg1s added a commit that referenced this pull request Oct 14, 2026
…159410)

gh-159320: Enable stack size detection on Android (GH-159321)

Extend the use of pthread_getattr_np in stack size detection from any glibc linux to any glibc *or* android linux. Update tests for android's new recursion limit.
(cherry picked from commit 8ff41c2)

Co-authored-by: T. Wouters <thomas@python.org>
Co-authored-by: Malcolm Smith <smith@chaquo.com>
Yhg1s added a commit that referenced this pull request Oct 14, 2026
…159409)

gh-159320: Enable stack size detection on Android (GH-159321)

Extend the use of pthread_getattr_np in stack size detection from any glibc linux to any glibc *or* android linux. Update tests for android's new recursion limit.
(cherry picked from commit 8ff41c2)

Co-authored-by: T. Wouters <thomas@python.org>
Co-authored-by: Malcolm Smith <smith@chaquo.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants