emscripten-core / emscripten-core/emscripten
[DOCU] Small description issue in fetch.h (requestHeaders)
- Dominant language
- C++
- Stars
- 27.6k
- Forks
- 3.6k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 105
Description
emscripten V2.0.9 upstream
fetch.h (original)
```
// Points to an array of strings to pass custom headers to the request. This array takes the form
// {"key1", "value1", "key2", "value2", "key3", "value3", ..., 0 }; Note especially that the array
// needs to be terminated with a null pointer.
const char * const *requestHeaders;
```
Will the attribute `requestHeaders` set with this values `{"key", "value", 0}`, then I have an exception on xhr setReqeustHeader with "invalid utf 8 leading byte".
Made I the call with null-terminated strings `{"key\0", "value\0", 0}`, then will the request working.
**This is not an important task or feedback, more for information.**
_I use C++20_
Contributor guide
Assessment
This issue has not been assessed yet.