diff --git a/devtools/create_project/create_project.cpp b/devtools/create_project/create_project.cpp index 0a2f6769002..193f3e3d78e 100644 --- a/devtools/create_project/create_project.cpp +++ b/devtools/create_project/create_project.cpp @@ -1887,6 +1887,9 @@ void ProjectProvider::addFilesToProject(const std::string &dir, std::ostream &pr const std::string &pchIncludeRoot, const StringList &pchDirs, const StringList &pchExclude, const std::string &filePrefix) { FileNode *files = scanFiles(dir, includeList, excludeList); + if (files == nullptr) { + return; + } writeFileListToProject(*files, projectFile, 0, std::string(), filePrefix + '/', pchIncludeRoot, pchDirs, pchExclude);