When passing in valid data with zero size, replaceWith() will do nothing and leave the MemoryBlock in its previous state which may be unexpected. replaceAll() will reset the MemoryBlock and resize it to 0
- Added a new URL::createInputStream() overload that takes an InputStreamOptions helper class to simplify stream creation.
- Modified the internals of URL and WebInputStream so that parameters are only added to the request body when ParameterHandling is set to inPostData. This allows POST data to be added via URL::withPOSTData() and sent with URL-encoded parameters.
The values in mach_timebase_info_data_t should be specified in terms of
'ticks'. On some machines, ticks may correspond to nanoseconds, but this
is not guaranteed.
Previously, if `stopTimer()` was called from within
`hiResTimerCallback()`, a call to `isTimerRunning()` immediately
following the call to `stopTimer()` would return true instead of false.
This patch fixes the issue, and adds some tests to verify the new
behaviour.
If an aiff file advertied a large number of metadata keys, the
StringPairArray::set calls resulted in quadratic complexity.
We now read keys into a std::map instead, as it enables much faster
lookup, and then convert back to a StringPairArray at the last possible
moment.
Previously we relied on Foundation.framework being implicitly linked by other frameworks, but this change is required when building with Xcode 12 targeting older macOS versions to fix missing CFNetwork symbols.