-Fixed error on no result for JSON Path queries

-Fixed not disposing JsonReader/JsonWriter in some places
This commit is contained in:
James Newton-King
2013-12-22 13:52:56 +13:00
parent 49a4a94d74
commit d529190b46
12 changed files with 294 additions and 72 deletions
+4 -3
View File
@@ -301,9 +301,10 @@ namespace Newtonsoft.Json.Schema
{
ValidationUtils.ArgumentNotNull(json, "json");
JsonReader reader = new JsonTextReader(new StringReader(json));
return Read(reader, resolver);
using (JsonReader reader = new JsonTextReader(new StringReader(json)))
{
return Read(reader, resolver);
}
}
/// <summary>