Closed tbeu closed 10 years ago
In msgpack_modelica_stream_get
res = ModelicaAllocateStringWithErrorReturn(st->size); memcpy(res,st->str,st->size); free(st->str); if (!res) { ModelicaError("Failed to allocate memory for stream\n"); }
res should be checked immediately after alloc not after memcpy.
In msgpack_modelica_stream_get
res should be checked immediately after alloc not after memcpy.