Blob Blame History Raw
From ea4aefaba7c4a6ad4e33b2a85f1802243696d293 Mon Sep 17 00:00:00 2001
From: Miklos Vajna <vmiklos@collabora.co.uk>
Date: Mon, 5 Oct 2015 11:29:02 +0200
Subject: [PATCH 171/398] desktop: handle sal_uInt16 in jsonToPropertyValues()

Change-Id: Ic0059404b7ccbc922703705e7818404d4904f324
(cherry picked from commit 44838c669b6bd02e14c394aebd9d19bcbf5ff409)
---
 desktop/source/lib/init.cxx | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 1f87146bacf8..a1356aa02ca1 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -902,6 +902,8 @@ static void jsonToPropertyValues(const char* pJSON, uno::Sequence<beans::Propert
                 aValue.Value <<= OString(rValue.c_str()).toFloat();
             else if (rType == "long")
                 aValue.Value <<= OString(rValue.c_str()).toInt32();
+            else if (rType == "unsigned short")
+                aValue.Value <<= static_cast<sal_uInt16>(OString(rValue.c_str()).toUInt32());
             else
                 SAL_WARN("desktop.lib", "jsonToPropertyValues: unhandled type '"<<rType<<"'");
             aArguments.push_back(aValue);
-- 
2.12.0