We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1af11d3 commit bb68b31Copy full SHA for bb68b31
shared/helpers/Serialization.cpp
@@ -528,7 +528,10 @@ alt::MValueByteArray V8Helpers::V8ToRawBytes(v8::Local<v8::Value> val)
528
if(!serializer.WriteValue(ctx, val).To(&result) || !result) return alt::MValueByteArray();
529
530
std::pair<uint8_t*, size_t> serialized = serializer.Release();
531
- return alt::ICore::Instance().CreateMValueByteArray(serialized.first, serialized.second);
+ auto mvArray = alt::ICore::Instance().CreateMValueByteArray(serialized.first, serialized.second);
532
+
533
+ delegate.FreeBufferMemory(serialized.first);
534
+ return mvArray;
535
}
536
537
// Converts a MValue byte array to a JS value
0 commit comments