### Godot version

master CI builds

### System information

Linux / Editor with doubles and GCC sanitizers

### Issue description

The `Linux / Editor with doubles and GCC sanitizers` build can fail with a `attempting free on address which was not malloc()-ed` crash in the `Open and close editor (Vulkan)` step.

https://github.com/godotengine/godot/actions/runs/5366302204/jobs/9735786296#step:15:138
https://github.com/godotengine/godot/actions/runs/5389199469/jobs/9783070708?pr=78740#step:15:138

The failure doesn't seem related to either PR (in fact one of them is just a docs change). I have only seen this issue these two times, still probably worth looking into.

### Steps to reproduce

Open and close https://github.com/godotengine/regression-test-project/archive/4.0.zip using the Vulkan renderer.

### Minimal reproduction project

https://github.com/godotengine/regression-test-project/archive/4.0.zip
print_verbose(String("Optional extension ") + String(requested_extension.key) + String(" not found"));
			}
		}
	}
	free(instance_extensions);
	instance_extensions_initialized = true;
	return OK;
}
bool VulkanContext::device_extensions_initialized = false;
HashMap<CharString, bool> VulkanContext::requested_device_extensions;
void VulkanContext::register_requested_device_extension(const CharString &extension_name, bool p_required) {
	ERR_FAIL_COND_MSG(device_extensions_initialized, "You can only registered extensions before the Vulkan instance is created");
	ERR_FAIL_COND(requested_device_extensions.has(extension_name));
	requested_device_extensions[extension_name] = p_required;
}
Error VulkanContext::_initialize_device_extensions() {
	
	enabled_device_extension_names.clear();
	
	register_requested_device_extension(VK_KHR_SWAPCHAIN_EXTENSION_NAME, true);
	register_requested_device_extension(VK_KHR_MULTIVIEW_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_FRAGMENT_SHADING_RATE_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_CREATE_RENDERPASS_2_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_SHADER_FLOAT16_INT8_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_STORAGE_BUFFER_STORAGE_CLASS_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_16BIT_STORAGE_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_IMAGE_FORMAT_LIST_EXTENSION_NAME, false);
	register_requested_device_extension(VK_KHR_MAINTENANCE_2_EXTENSION_NAME, false);
	if (Engine::get_singleton()->is_generate_spirv_debug_info_enabled()) {
		register_requested_device_extension(VK_KHR_SHADER_NON_SEMANTIC_INFO_EXTENSION_NAME, true);