Fix crash due to null pointer dereference when moving/renaming folders in FileSystemDock

(cherry picked from commit 4e3a39a2e8)
This commit is contained in:
Artemy Fedotov 2025-09-11 14:25:49 +04:00 committed by Rémi Verschelde
parent 1c078fee01
commit 83a78186ca
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -2033,6 +2033,7 @@ void FileSystemDock::_before_move(HashMap<String, ResourceUID::ID> &r_uids, Hash
}
} else {
EditorFileSystemDirectory *current_folder = EditorFileSystem::get_singleton()->get_filesystem_path(to_move[i].path);
ERR_CONTINUE(current_folder == nullptr);
List<EditorFileSystemDirectory *> folders;
folders.push_back(current_folder);
while (folders.front()) {