From e18db6fe608acd54cd2ab6c5faedb34f55bd3b92 Mon Sep 17 00:00:00 2001 From: Hilderin <81109165+Hilderin@users.noreply.github.com> Date: Mon, 24 Jun 2024 17:35:52 -0400 Subject: [PATCH] Fix editor crash when invalid global class script path --- modules/gdscript/gdscript_analyzer.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/gdscript/gdscript_analyzer.cpp b/modules/gdscript/gdscript_analyzer.cpp index aa26bb222daa..c60672d3f44f 100644 --- a/modules/gdscript/gdscript_analyzer.cpp +++ b/modules/gdscript/gdscript_analyzer.cpp @@ -5527,6 +5527,9 @@ bool GDScriptAnalyzer::check_type_compatibility(const GDScriptParser::DataType & // A script type cannot be a subtype of a GDScript class. return false; } + if (p_source.script_type.is_null()) { + return false; + } if (p_source.is_meta_type) { src_native = p_source.script_type->get_class_name(); } else {