Commit 2f0d8a4f authored by Clownacy's avatar Clownacy Committed by David Reid

Fix an ANSI C incompatibility.

parent 2fde0c69
......@@ -12270,12 +12270,15 @@ MA_API int ma_strappend(char* dst, size_t dstSize, const char* srcA, const char*
MA_API char* ma_copy_string(const char* src, const ma_allocation_callbacks* pAllocationCallbacks)
{
size_t sz;
char* dst;
if (src == NULL) {
return NULL;
}
size_t sz = strlen(src)+1;
char* dst = (char*)ma_malloc(sz, pAllocationCallbacks);
sz = strlen(src)+1;
dst = (char*)ma_malloc(sz, pAllocationCallbacks);
if (dst == NULL) {
return NULL;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment