Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not crash on tid == -1 in sys_thr_set_name #667

Merged
merged 2 commits into from
Feb 23, 2024

Conversation

mikusp
Copy link
Contributor

@mikusp mikusp commented Feb 18, 2024

Previous implementation thought of tid == -1 but it crashed on unwrapping the conversion to i32. This is called by system app ShellAppProxy

src/kernel/src/process/mod.rs Outdated Show resolved Hide resolved
@mikusp mikusp force-pushed the handle_negative_tid_in_thr_set_name branch from 7645db4 to 5d55551 Compare February 18, 2024 16:54
@VocalFan VocalFan merged commit d1c2463 into obhq:main Feb 23, 2024
6 checks passed
@ultimaweapon
Copy link
Member

Actually this is not the correct way to fix this. This is a bug in the value conversion code.

@SuchAFuriousDeath
Copy link
Contributor

SuchAFuriousDeath commented Feb 24, 2024

I told VocalFan to merge this, because it's already done this way in sys_cpuset_getaffinity, so I assumed that it's acceptable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants