22 Jan
2025
22 Jan
'25
9:07 a.m.
Rémi Bernon (@rbernon) commented about dlls/windows.web/json_value.c:
+ result = wcstold( json, &end ); + + if (errno == ERANGE) return WEB_E_INVALID_JSON_NUMBER; + if (errno || end != json + json_len) return WEB_E_INVALID_JSON_NUMBER; + + impl->parsed_number = result; + impl->json_value_type = JsonValueType_Number; + } + + return hr; +} + +static HRESULT parse_json( HSTRING json, struct json_value *impl ) +{ + HSTRING trimmed_json = NULL; + HRESULT hr = trim_string( json, L" ", &trimmed_json ); What about newlines, tabs and other whitespaces which are probably allowed?
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/6966#note_92456