mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-09 16:48:43 +08:00
[cpp] Closes #2563, free input and skeleton data on parsing failure.
This commit is contained in:
parent
578084806d
commit
82cb7f5cad
@ -125,6 +125,8 @@ SkeletonData *SkeletonBinary::readSkeletonData(const unsigned char *binary, cons
|
||||
char errorMsg[255];
|
||||
snprintf(errorMsg, 255, "Skeleton version %s does not match runtime version %s", skeletonData->_version.buffer(), SPINE_VERSION_STRING);
|
||||
setError(errorMsg, "");
|
||||
delete input;
|
||||
delete skeletonData;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user