Fix gltf json parsing error due to insufficient buffer padding.
Some checks failed
CMake on multiple platforms / build (Release, cl, cl, windows-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, clang, clang++, macos-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, clang, clang++, ubuntu-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, gcc, g++, ubuntu-latest) (push) Has been cancelled
Some checks failed
CMake on multiple platforms / build (Release, cl, cl, windows-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, clang, clang++, macos-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, clang, clang++, ubuntu-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, gcc, g++, ubuntu-latest) (push) Has been cancelled
This commit is contained in:
@@ -450,7 +450,7 @@ KRBundle* KRResource::LoadGltf(KRContext& context, const std::string& path)
|
||||
|
||||
jsonData.expand(SIMDJSON_PADDING);
|
||||
jsonData.lock();
|
||||
auto error = parser.iterate((const char*)jsonData.getStart(), jsonData.getSize()).get(doc);
|
||||
auto error = parser.iterate((uint8_t*)jsonData.getStart(), jsonData.getSize() - SIMDJSON_PADDING, jsonData.getSize()).get(doc);
|
||||
jsonData.unlock();
|
||||
|
||||
if (error) {
|
||||
|
||||
Reference in New Issue
Block a user