From 39bde8078c5f955139d8375f998f2c1eccbd3e67 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Wed, 10 Aug 2016 11:14:33 +0200 Subject: [PATCH] Disallow casting "" to an Object fixes #12390 --- lib/base/value.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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()) -- 2.40.0