From 006d7890f68a3534ef695a6a522b1dc03b54f749 Mon Sep 17 00:00:00 2001 From: eidheim Date: Mon, 21 Dec 2015 15:30:30 +0100 Subject: [PATCH] Another minor fix to build path error handling --- src/cmake.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cmake.cc b/src/cmake.cc index 2e99f83..0d8ab02 100644 --- a/src/cmake.cc +++ b/src/cmake.cc @@ -33,7 +33,8 @@ CMake::CMake(const boost::filesystem::path &path) { } if(!project_path.empty()) { - if(!boost::filesystem::exists(get_default_build_path(project_path)/"compile_commands.json")) + auto default_build_path=get_default_build_path(project_path); + if(!default_build_path.empty() && !boost::filesystem::exists(default_build_path/"compile_commands.json")) create_compile_commands(project_path); } }