Skip to content

IoUring: Use correct errno value in exception#16500

Merged
chrisvest merged 1 commit into
4.2from
native_ex
Mar 17, 2026
Merged

IoUring: Use correct errno value in exception#16500
chrisvest merged 1 commit into
4.2from
native_ex

Conversation

@normanmaurer
Copy link
Copy Markdown
Member

Motivation:
io_uring_mmap() returns -errno on failure so we need to negating it

Modifications:

  • Changed ret to -ret

Result:
Since io_uring_mmap() returns -errno on failure, negating it recovers the positive errno value that throwRuntimeExceptionErrorNo expects for a meaningful error message.

Motivation:
io_uring_mmap() returns -errno on failure so we need to negating it

Modifications:
- Changed ret to -ret

Result:
Since io_uring_mmap() returns -errno on failure, negating it recovers the positive errno value that throwRuntimeExceptionErrorNo expects for a meaningful error message.
@normanmaurer normanmaurer added this to the 4.2.11.Final milestone Mar 17, 2026
@normanmaurer normanmaurer added the needs-cherry-pick-5.0 This PR should be cherry-picked to 5.0 once merged. label Mar 17, 2026
@chrisvest chrisvest merged commit 48162ce into 4.2 Mar 17, 2026
49 of 54 checks passed
@chrisvest chrisvest deleted the native_ex branch March 17, 2026 20:22
netty-project-bot pushed a commit that referenced this pull request Mar 17, 2026
Motivation:
io_uring_mmap() returns -errno on failure so we need to negating it

Modifications:
- Changed ret to -ret

Result:
Since io_uring_mmap() returns -errno on failure, negating it recovers
the positive errno value that throwRuntimeExceptionErrorNo expects for a
meaningful error message.

(cherry picked from commit 48162ce)
@netty-project-bot
Copy link
Copy Markdown
Contributor

Auto-port PR for 5.0: #16515

@github-actions github-actions Bot removed the needs-cherry-pick-5.0 This PR should be cherry-picked to 5.0 once merged. label Mar 17, 2026
chrisvest pushed a commit that referenced this pull request Mar 18, 2026
Auto-port of #16500 to 5.0
Cherry-picked commit: 48162ce

---
Motivation:
io_uring_mmap() returns -errno on failure so we need to negating it

Modifications:
- Changed ret to -ret

Result:
Since io_uring_mmap() returns -errno on failure, negating it recovers
the positive errno value that throwRuntimeExceptionErrorNo expects for a
meaningful error message.

Co-authored-by: Norman Maurer <norman_maurer@apple.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants