Commit Graph
9 Commits
Author SHA1 Message Date
Adrià fdd526186e Merge pull request #12581 from JJenkx/windows/libc-strtok-s-c11
fix(libc): take strtok_s's C11 s1max argument as titles' libc.prx does
2026-11-05 20:14:27 +01:00
AdriàandClaude Sonnet 5.5 13a8cd50f7 test(libc): pin bsearch_s RSIZE_MAX count and element size boundaries
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-29 03:43:00 +01:00
JJenkx 39f432f357 fix(libc): allow zero-stride bsearch_s as bundled libc does 2026-10-28 22:17:34 -04:00
JJenkxandClaude Opus 5.5 65ac15cd8f test(libc): cover more strtok_s argument and boundary cases
A null s1max or ptr, a token that fills s1max, the largest valid
s1max, and unchanged state after missing delimiter and missing token.
Every expected value matches titles' libc.prx (PPSA07923, PPSA05916).
Suggested by rooklz in review.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-28 19:02:44 -04:00
JJenkxandClaude Opus 5.5 fefc3f1d98 fix(libc): take strtok_s's C11 s1max argument as titles' libc.prx does
The strtok_s that titles' libc.prx exports (NID -vXEQdRADLI, PPSA07923
and PPSA05916) is the C11 Annex K form strtok_s(s1, s1max, s2, ptr).
main implemented the Microsoft form strtok_s(str, delim, context), so
a title's s1max pointer was read as the delimiter string and its
delimiters as the context. The function now takes s1max, stops within
it, updates it, and reports "strtok_s: bad argument", "missing token"
and "missing delimiter" through the constraint handler with EINVAL, as
wcstok_s already does. libSceAmpr re-exports the same NID and changes
with it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-28 17:18:47 -04:00
fogydes 1af5f0735f fix(libc): invoke constraint handler on zero element size in bsearch_s 2026-10-28 13:31:49 +05:30
boykopovar f38d29fd08 refactor(sdk): add canonical headers for remaining libraries 2026-10-24 23:17:42 +03:00
hypermistandClaude Opus 5.5 d06dfb1caf fix(libc): stage wctomb_s and wcrtomb_s through _Getmbcurmax and pin their UTF-8 results
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01RbLgECLQ2bpDM7oe2urGZK
2026-10-22 14:41:50 +13:00
hypermistandClaude Opus 5.5 2c1f9672a3 feat(libc): implement the remaining C11 Annex K bounds-checking functions
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-19 23:18:09 +13:00