Add error checking for " at the end of injected cmake blocks

vcpkg-wip
Duncan Ogilvie 4 years ago
parent 555c2d04ef
commit 8e163522c7

@ -330,6 +330,9 @@ int generate_cmake(const char *path, bool root) {
};
auto inject_cmake = [&ss, &tolf](const std::string &cmake) {
if (!cmake.empty()) {
if (cmake.back() == '\"') {
throw std::runtime_error("Detected additional \" at the end of cmake block");
}
ss << tolf(cmake) << "\n\n";
}
};

Loading…
Cancel
Save