Skip to content

Internal error, property list was not freed by engine! (Regression crash) #115017

@DevPrice

Description

@DevPrice

Tested versions

  • Reproducible in: v4.6.rc1.official [481f36e], v4.6.beta3.official [76dda5c], v4.6.beta2.official [551ce8d]
  • Not reproducible in: v4.5, v4.5.1 stable, 4.6 dev 1, v4.6.dev2.official [7864ac8], v4.6.dev3.official [9d84f3d], v4.6.dev5.official [f5918a9], v4.6.beta1.official [d743736]

System information

Godot v4.6.rc1 - Windows 11 (build 26200) - Multi-window, 2 monitors - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3080 (NVIDIA; 32.0.15.9144) - AMD Ryzen 9 9950X 16-Core Processor (32 threads) - 61.63 GiB memory

Issue description

Godot crashes whenever I select a node that exposes my properties in the property inspector. This node is implemented in a GDExtension targeting godot-cpp 4.5.

Steps to reproduce

  1. Open the sample project in https://github.com/DevPrice/godot-slang
  2. Select "WorldEnvironment" in the scene tree.
  3. Observe the crash.
C:\Apps\Godot_v4.6-rc1_win64.exe\Godot_v4.6-rc1_win64.exe --path demo -e
Godot Engine v4.6.rc1.official.481f36ed2 - https://godotengine.org
Vulkan 1.4.325 - Forward+ - Using Device #0: NVIDIA - NVIDIA GeForce RTX 3080

ERROR: Internal error, property list was not freed by engine!
   at: ComputeShaderTask::get_property_list_bind (C:\projects\godot-slang\src\compute_shader_task.h:14)
Exception: Exception 0xc0000005 encountered at address 0x7ff6cd702d31: Access violation reading location 0x00000000

Minimal reproduction project (MRP)

I can try to put together a simpler MRP later if needed, but the project that triggers the crash is available here: https://github.com/DevPrice/godot-slang

Relevant _get_property_list implementation:

void ComputeShaderTask::_get_property_list(List<PropertyInfo>* p_list) const {
	ERR_FAIL_NULL(p_list);
	_get_property_list(p_list, "shader_parameter/", get_shader_parameters());
}

void ComputeShaderTask::_get_property_list(List<PropertyInfo>* p_list, const String& prefix, const Dictionary& properties) {
	ERR_FAIL_NULL(p_list);
	for (const StringName property_name : properties.keys()) {
		const Dictionary property = properties.get(property_name, Dictionary());
		PropertyInfo property_info = PropertyInfo::from_dict(property.get("property_info", Dictionary()));
		property_info.name = prefix + property_info.name;
		if (_can_show_property_info(property_info)) {
			p_list->push_back(property_info);
		} else {
			const Ref<ShaderTypeLayoutShape> property_shape = property.get("shape", nullptr);
			if (const auto structured_shape = cast_to<StructTypeLayoutShape>(property_shape.ptr())) {
				_get_property_list(p_list, String("%s%s/") % TypedArray<String> { prefix, property_name }, structured_shape->get_properties());
			}
		}
	}
}

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Very Bad

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions