### Godot version

4.0.dev.935a6ef46b7c6af4239b6adce41b8198f051b57a

### System information

macOS 13.1

### Issue description

EDIT: Will be fixed by https://github.com/godotengine/godot/pull/72440

The GLTF importer crashes the engine when importing models from a file at runtime.

I have not traced the issue fully yet, but it was introduced sometime in the last 5 days, between d1e5903c67956707948b1de370b807e3aad395b7 and 935a6ef46b7c6af4239b6adce41b8198f051b57a

```
  ================================================================
  handle_crash: Program crashed with signal 11
  Engine version: Godot Engine v4.0.beta.mirror (024c2181d5173f5b4ebf202dd3252b488ec34bc4)
  Dumping the backtrace. Please include this when reporting the bug to the project developer.
  [1] 1   libsystem_platform.dylib            0x00000001854632a4 _sigtramp + 56
  [2] GLTFDocument::_parse_images(Ref<GLTFState>, String const&) (in godot.macos.editor.arm64) + 9080
  [3] GLTFDocument::_parse_gltf_state(Ref<GLTFState>, String const&) (in godot.macos.editor.arm64) + 684
  [4] GLTFDocument::_parse(Ref<GLTFState>, String, Ref<FileAccess>) (in godot.macos.editor.arm64) + 1976
  [5] GLTFDocument::append_from_file(String, Ref<GLTFState>, unsigned int, String) (in godot.macos.editor.arm64) + 780
```

Full stack trace:

<details>

```
  ================================================================
  handle_crash: Program crashed with signal 11
  Engine version: Godot Engine v4.0.beta.mirror (024c2181d5173f5b4ebf202dd3252b488ec34bc4)
  Dumping the backtrace. Please include this when reporting the bug to the project developer.
  [1] 1   libsystem_platform.dylib            0x00000001854632a4 _sigtramp + 56
  [2] GLTFDocument::_parse_images(Ref<GLTFState>, String const&) (in godot.macos.editor.arm64) + 9080
  [3] GLTFDocument::_parse_gltf_state(Ref<GLTFState>, String const&) (in godot.macos.editor.arm64) + 684
  [4] GLTFDocument::_parse(Ref<GLTFState>, String, Ref<FileAccess>) (in godot.macos.editor.arm64) + 1976
  [5] GLTFDocument::append_from_file(String, Ref<GLTFState>, unsigned int, String) (in godot.macos.editor.arm64) + 780
  [6] GLTFDocument::_parse_gltf_extensions(Ref<GLTFState>)
  [7] GLTFDocument::_parse_gltf_extensions(Ref<GLTFState>)
  [8] GLTFDocument::_parse_gltf_extensions(Ref<GLTFState>)
  [9] GDScriptFunction::call(GDScriptInstance*, Variant const**, int, Callable::CallError&, GDScriptFunction::CallState*) (in godot.macos.editor.arm64) + 73812
  [10] Variant::callp(StringName const&, Variant const**, int, Variant&, Callable::CallError&) (in godot.macos.editor.arm64) + 228
  [11] GDScriptFunction::call(GDScriptInstance*, Variant const**, int, Callable::CallError&, GDScriptFunction::CallState*) (in godot.macos.editor.arm64) + 63144
  [12] GDScriptInstance::callp(StringName const&, Variant const**, int, Callable::CallError&) (in godot.macos.editor.arm64) + 348
  [13] Object::callp(StringName const&, Variant const**, int, Callable::CallError&) (in godot.macos.editor.arm64) + 188
  [14] Callable::callp(Variant const**, int, Variant&, Callable::CallError&) const (in godot.macos.editor.arm64) + 176
  [15] CallableCustomBind::call(Variant const**, int, Variant&, Callable::CallError&) const (in godot.macos.editor.arm64) + 452
  [16] core_bind::Thread::_start_func(void*) (in godot.macos.editor.arm64) + 552
  [17] Thread::callback(Thread*, Thread::Settings const&, void (*)(void*), void*) (in godot.macos.editor.arm64) + 176
  [18] Thread::~Thread()
  [19] 19  libsystem_pthread.dylib             0x000000018543506c _pthread_start + 148
```

</details>

### Steps to reproduce

Occurs when importing GLTF models at runtime. The same models import correctly when placed in the `res://` folder and imported by the editor. I will try to isolate this to a single model (or maybe it occurs on all? dunno yet).

### Minimal reproduction project

It occurs on my company's project, I will try to reproduce it in a smaller project, but wanted to open this issue ASAP in case someone already has an idea of what would be causing this.
material_name = mat->get_name();
		}
		Array blend_arrays;
		if (array_mesh.is_valid()) {
			blend_arrays = array_mesh->surface_get_blend_shape_arrays(surface_i);
		}
		importer_mesh->add_surface(mesh->surface_get_primitive_type(surface_i), mesh->surface_get_arrays(surface_i),
				blend_arrays, mesh->surface_get_lods(surface_i), mat, material_name, mesh->surface_get_format(surface_i));
	}
	gltf_mesh->set_mesh(importer_mesh);
	GLTFMeshIndex mesh_index = p_state->meshes.size();
	p_state->meshes.push_back(gltf_mesh);
	for (int32_t instance_i = 0; instance_i < multi_mesh->get_instance_count();
			instance_i++) {
		Transform3D transform;
		if (multi_mesh->get_transform_format() == MultiMesh::TRANSFORM_2D) {
			Transform2D xform_2d = multi_mesh->get_instance_transform_2d(instance_i);
			transform.origin =
					Vector3(xform_2d.get_origin().x, 0, xform_2d.get_origin().y);
			real_t rotation = xform_2d.get_rotation();
			Quaternion quaternion(Vector3(0, 1, 0), rotation);
			Size2 scale = xform_2d.get_scale();
			transform.basis.set_quaternion_scale(quaternion,
					Vector3(scale.x, 0, scale.y));
			transform = p_multi_mesh_instance->get_transform() * transform;
		} else if (multi_mesh->get_transform_format() == MultiMesh::TRANSFORM_3D) {
			transform = p_multi_mesh_instance->get_transform() *
					multi_mesh->get_instance_transform(instance_i);
		}
		Ref<GLTFNode> new_gltf_node;