From b6907f417b33d089c509516ca09961623860d06e Mon Sep 17 00:00:00 2001 From: Alexander Karatarakis Date: Tue, 28 Feb 2017 19:58:19 -0800 Subject: Use Checks::check_exit() --- toolsrc/src/commands_integrate.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/toolsrc/src/commands_integrate.cpp b/toolsrc/src/commands_integrate.cpp index edb35d33a..6d28da6ab 100644 --- a/toolsrc/src/commands_integrate.cpp +++ b/toolsrc/src/commands_integrate.cpp @@ -272,12 +272,7 @@ namespace vcpkg::Commands::Integrate const int exit_code = System::cmd_execute(cmd_line); const fs::path nuget_package = buildsystems_dir / Strings::format("%s.%s.nupkg", nuget_id, nupkg_version); - if (exit_code != 0 || !fs::exists(nuget_package)) - { - System::println(System::color::error, "Error: NuGet package creation failed"); - exit(EXIT_FAILURE); - } - + Checks::check_exit(exit_code == 0 && fs::exists(nuget_package), "Error: NuGet package creation failed"); System::println(System::color::success, "Created nupkg: %s", nuget_package.string()); System::println(R"( -- cgit v1.2.3