-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
The existing request_builder_body function only works with text data because it:
- Expects a C string (*const c_char): assumes null-terminated text
- Validates UTF-8 encoding: calls CStr::from_ptr(body).to_str() which fails on non-UTF-8 bytes
- Rejects binary data: returns error "Body contains invalid UTF-8" when it encounters bytes like 0x00, 0xFF, etc.
What request_builder_body_binary Provides:
- Accepts raw bytes (*const u8 + length): no assumption about text format
- No UTF-8 validation: treats data as pure binary
- Works with any file type: videos, images, PDFs, executables, etc.
Metadata
Metadata
Assignees
Labels
No labels