From 613e6a25e8e38343443a3cbbeb52b311ea35be4f Mon Sep 17 00:00:00 2001 From: Latif Khalifa Date: Sat, 13 Mar 2010 11:17:48 +0000 Subject: [PATCH] LIBOMV-798: OSDParser.DeserializeJson() throws an exception on null values git-svn-id: http://libopenmetaverse.googlecode.com/svn/libopenmetaverse/trunk@3273 52acb1d6-8a22-11de-b505-999d5b087335 --- OpenMetaverse.StructuredData/JSON/OSDJson.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/OpenMetaverse.StructuredData/JSON/OSDJson.cs b/OpenMetaverse.StructuredData/JSON/OSDJson.cs index 254c34ed..8761c92a 100644 --- a/OpenMetaverse.StructuredData/JSON/OSDJson.cs +++ b/OpenMetaverse.StructuredData/JSON/OSDJson.cs @@ -25,6 +25,8 @@ namespace OpenMetaverse.StructuredData public static OSD DeserializeJson(JsonData json) { + if (json == null) return new OSD(); + switch (json.GetJsonType()) { case JsonType.Boolean: