Merge branch '3.2.x'
This commit is contained in:
@@ -51,7 +51,8 @@ class JSON {
|
||||
try {
|
||||
return Double.valueOf((String) value);
|
||||
}
|
||||
catch (NumberFormatException ignored) {
|
||||
catch (NumberFormatException ex) {
|
||||
// Ignore
|
||||
}
|
||||
}
|
||||
return null;
|
||||
@@ -68,7 +69,8 @@ class JSON {
|
||||
try {
|
||||
return (int) Double.parseDouble((String) value);
|
||||
}
|
||||
catch (NumberFormatException ignored) {
|
||||
catch (NumberFormatException ex) {
|
||||
// Ignore
|
||||
}
|
||||
}
|
||||
return null;
|
||||
@@ -85,7 +87,8 @@ class JSON {
|
||||
try {
|
||||
return (long) Double.parseDouble((String) value);
|
||||
}
|
||||
catch (NumberFormatException ignored) {
|
||||
catch (NumberFormatException ex) {
|
||||
// Ignore
|
||||
}
|
||||
}
|
||||
return null;
|
||||
|
||||
@@ -827,7 +827,8 @@ public class JSONObject {
|
||||
return o.toString();
|
||||
}
|
||||
}
|
||||
catch (Exception ignored) {
|
||||
catch (Exception ex) {
|
||||
// Ignore
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -320,7 +320,8 @@ public class JSONTokener {
|
||||
try {
|
||||
return Double.valueOf(literal);
|
||||
}
|
||||
catch (NumberFormatException ignored) {
|
||||
catch (NumberFormatException ex) {
|
||||
// Ignore
|
||||
}
|
||||
|
||||
/* ... finally give up. We have an unquoted string */
|
||||
|
||||
Reference in New Issue
Block a user