File tree Expand file tree Collapse file tree 2 files changed +7
-13
lines changed Expand file tree Collapse file tree 2 files changed +7
-13
lines changed Original file line number Diff line number Diff line change @@ -1646,9 +1646,7 @@ public String toString() {
1646
1646
@ SuppressWarnings ("resource" )
1647
1647
public String toString (int indentFactor ) throws JSONException {
1648
1648
StringWriter sw = new StringWriter ();
1649
- synchronized (sw .getBuffer ()) {
1650
- return this .write (sw , indentFactor , 0 ).toString ();
1651
- }
1649
+ return this .write (sw , indentFactor , 0 ).toString ();
1652
1650
}
1653
1651
1654
1652
/**
Original file line number Diff line number Diff line change @@ -2183,13 +2183,11 @@ public Object optQuery(JSONPointer jsonPointer) {
2183
2183
@ SuppressWarnings ("resource" )
2184
2184
public static String quote (String string ) {
2185
2185
StringWriter sw = new StringWriter ();
2186
- synchronized (sw .getBuffer ()) {
2187
- try {
2188
- return quote (string , sw ).toString ();
2189
- } catch (IOException ignored ) {
2190
- // will never happen - we are writing to a string writer
2191
- return "" ;
2192
- }
2186
+ try {
2187
+ return quote (string , sw ).toString ();
2188
+ } catch (IOException ignored ) {
2189
+ // will never happen - we are writing to a string writer
2190
+ return "" ;
2193
2191
}
2194
2192
}
2195
2193
@@ -2576,9 +2574,7 @@ public String toString() {
2576
2574
@ SuppressWarnings ("resource" )
2577
2575
public String toString (int indentFactor ) throws JSONException {
2578
2576
StringWriter w = new StringWriter ();
2579
- synchronized (w .getBuffer ()) {
2580
- return this .write (w , indentFactor , 0 ).toString ();
2581
- }
2577
+ return this .write (w , indentFactor , 0 ).toString ();
2582
2578
}
2583
2579
2584
2580
/**
You can’t perform that action at this time.
0 commit comments