diff options
-rw-r--r-- | modules/fbx/editor_scene_importer_fbx.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/fbx/editor_scene_importer_fbx.cpp b/modules/fbx/editor_scene_importer_fbx.cpp index 4d15ca93c1..55d524883f 100644 --- a/modules/fbx/editor_scene_importer_fbx.cpp +++ b/modules/fbx/editor_scene_importer_fbx.cpp @@ -104,6 +104,9 @@ Node3D *EditorSceneImporterFBX::import_scene(const String &p_path, uint32_t p_fl bool is_binary = false; data.resize(f->get_len()); + + ERR_FAIL_COND_V(data.size() < 64, NULL); + f->get_buffer(data.ptrw(), data.size()); PackedByteArray fbx_header; fbx_header.resize(64); |