fix issue 249

This commit is contained in:
goyuken 2014-08-15 15:52:08 +00:00
parent 76c63ed5c6
commit 14282c4740
1 changed files with 6 additions and 1 deletions

View File

@ -86,7 +86,12 @@ namespace BizHawk.Client.Common
using (JsonTextReader jr = new JsonTextReader(tr))
{
TypeNameEncapsulator tne = (TypeNameEncapsulator)Serializer.Deserialize(jr, typeof(TypeNameEncapsulator));
return tne.o;
// in the case of trying to deserialize nothing, tne will be nothing
// we want to return nothing
if (tne != null)
return tne.o;
else
return null;
}
}