Changeset 9184 in josm for trunk/src/org/openstreetmap/josm/tools
- Timestamp:
- 2015-12-28T00:02:30+01:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/tools/HttpClient.java
r9182 r9184 104 104 try { 105 105 connection.connect(); 106 if (reasonForRequest != null && "".equalsIgnoreCase(reasonForRequest)) { 107 Main.info("{0} {1} ({2}) -> {3}", requestMethod, url, reasonForRequest, connection.getResponseCode()); 108 } else { 109 Main.info("{0} {1} -> {2}", requestMethod, url, connection.getResponseCode()); 110 } 106 final boolean hasReason = reasonForRequest != null && "".equalsIgnoreCase(reasonForRequest); 107 Main.info("{0} {1}{2} -> {3}{4}", 108 requestMethod, url, hasReason ? " (" + reasonForRequest + ")" : "", 109 connection.getResponseCode(), 110 connection.getContentLengthLong() > 0 ? " (" + connection.getContentLengthLong() / 1024 + "KB)" : "" 111 ); 111 112 if (Main.isDebugEnabled()) { 112 113 Main.debug("RESPONSE: " + connection.getHeaderFields()); 113 114 } 114 115 } catch (IOException e) { 116 Main.info("{0} {1} -> !!!", requestMethod, url); 115 117 Main.warn(e); 116 118 //noinspection ThrowableResultOfMethodCallIgnored
Note:
See TracChangeset
for help on using the changeset viewer.
