From: Gunnar Beutner Date: Wed, 10 Aug 2016 09:14:33 +0000 (+0200) Subject: Disallow casting "" to an Object X-Git-Tag: v2.5.0~101 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=39bde8078c5f955139d8375f998f2c1eccbd3e67;p=icinga2 Disallow casting "" to an Object fixes #12390 --- diff --git a/lib/base/value.hpp b/lib/base/value.hpp index 96be16d9f..3d12a262e 100644 --- a/lib/base/value.hpp +++ b/lib/base/value.hpp @@ -144,7 +144,7 @@ public: template operator intrusive_ptr(void) const { - if (IsEmpty()) + if (IsEmpty() && !IsString()) return intrusive_ptr(); if (!IsObject())