mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Made an assertion in MemoryOutputStream::write() slightly more forgiving
This commit is contained in:
parent
6f5b15e345
commit
dca741a01d
1 changed files with 2 additions and 2 deletions
|
|
@ -101,11 +101,11 @@ char* MemoryOutputStream::prepareToWrite (size_t numBytes)
|
|||
|
||||
bool MemoryOutputStream::write (const void* const buffer, size_t howMany)
|
||||
{
|
||||
jassert (buffer != nullptr);
|
||||
|
||||
if (howMany == 0)
|
||||
return true;
|
||||
|
||||
jassert (buffer != nullptr);
|
||||
|
||||
if (auto* dest = prepareToWrite (howMany))
|
||||
{
|
||||
memcpy (dest, buffer, howMany);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue