From a75d7d69ec2826227f13d373f00c4cbb267e8166 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Tue, 21 Feb 2017 10:59:43 +0100 Subject: [PATCH] Fix incorrect argument for Application::GetExePath fixes #4709 --- lib/remote/configpackageutility.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/remote/configpackageutility.cpp b/lib/remote/configpackageutility.cpp index 13e640cb7..9c0d1bbf3 100644 --- a/lib/remote/configpackageutility.cpp +++ b/lib/remote/configpackageutility.cpp @@ -201,9 +201,11 @@ void ConfigPackageUtility::TryActivateStageCallback(const ProcessResult& pr, con void ConfigPackageUtility::AsyncTryActivateStage(const String& packageName, const String& stageName) { + VERIFY(Application::GetArgC() >= 1); + // prepare arguments Array::Ptr args = new Array(); - args->Add(Application::GetExePath("icinga2")); + args->Add(Application::GetExePath(Application::GetArgV()[0])); args->Add("daemon"); args->Add("--validate"); args->Add("--define"); -- 2.40.0