Changeset 18816 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2023-08-22T17:26:18+02:00 (15 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/io/OsmJsonReader.java
r18723 r18816 4 4 import static org.openstreetmap.josm.tools.I18n.tr; 5 5 6 import java.io.IOException; 6 7 import java.io.InputStream; 7 import java.net.SocketException;8 8 import java.util.Collection; 9 9 import java.util.Map.Entry; … … 33 33 /** 34 34 * Parser for the Osm API (JSON output). Read from an input stream and construct a dataset out of it. 35 * 35 * <p> 36 36 * For each json element, there is a dedicated method. 37 37 * @since 14086 … … 190 190 throw new IllegalDataException(exception); 191 191 } catch (JsonException exception) { 192 if (exception.getCause() instanceof SocketException) {193 SocketException soe = (SocketException) exception.getCause();192 if (exception.getCause() instanceof IOException) { 193 IOException soe = (IOException) exception.getCause(); 194 194 soe.addSuppressed(exception); // Add the caught exception as a suppressed exception 195 195 throw new IllegalDataException(soe); // NOPMD -- PreserveStackTrace should be fixed with PMD 7
Note:
See TracChangeset
for help on using the changeset viewer.