-Test
This commit is contained in:
@@ -56,8 +56,7 @@ namespace Newtonsoft.Json
|
||||
public class JsonTextReader : JsonReader, IJsonLineInfo
|
||||
{
|
||||
private const char UnicodeReplacementChar = '\uFFFD';
|
||||
|
||||
private const int MaximumJavascriptIntegerLengthInCharacters = 380;
|
||||
private const int MaximumJavascriptIntegerCharacterLength = 380;
|
||||
|
||||
private readonly TextReader _reader;
|
||||
private char[] _chars;
|
||||
@@ -1270,10 +1269,10 @@ namespace Newtonsoft.Json
|
||||
{
|
||||
#if !(NET20 || NET35 || PORTABLE40 || PORTABLE)
|
||||
string number = _stringReference.ToString();
|
||||
if (number.Length > MaximumJavascriptIntegerLengthInCharacters)
|
||||
|
||||
if (number.Length > MaximumJavascriptIntegerCharacterLength)
|
||||
throw JsonReaderException.Create(this, "JSON integer {0} is too large to parse.".FormatWith(CultureInfo.InvariantCulture, _stringReference.ToString()));
|
||||
|
||||
|
||||
numberValue = BigInteger.Parse(number, CultureInfo.InvariantCulture);
|
||||
numberType = JsonToken.Integer;
|
||||
#else
|
||||
|
||||
Reference in New Issue
Block a user