]> granicus.if.org Git - icinga2/commitdiff
Fix incorrect exception type
authorGunnar Beutner <gunnar@beutner.name>
Wed, 14 Jan 2015 14:55:28 +0000 (15:55 +0100)
committerGunnar Beutner <gunnar@beutner.name>
Wed, 14 Jan 2015 14:57:48 +0000 (15:57 +0100)
refs #81659

lib/base/scriptfunction-script.cpp

index b6a1eaff4139cbc39e2db5dd23b3d92ba27dcd23..1ba64d6666ea278fcea5dac12ffcf2910ec7471f 100644 (file)
@@ -27,7 +27,7 @@ using namespace icinga;
 static Value ScriptFunctionCall(const std::vector<Value>& args)
 {
        if (args.size() < 1)
-               BOOST_THROW_EXCEPTION(ScriptError("Too few arguments for call()"));
+               BOOST_THROW_EXCEPTION(std::invalid_argument("Too few arguments for call()"));
 
        ScriptFrame *vframe = ScriptFrame::GetCurrentFrame();
        ScriptFunction::Ptr self = static_cast<ScriptFunction::Ptr>(vframe->Self);