Ignore:
Timestamp:
2016-04-27T12:47:30+02:00 (8 years ago)
Author:
bastiK
Message:

partial revert of [9529] (fixes #12583)

possibly breaking tests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/HttpClient.java

    r9977 r10160  
    110110            connection.setFixedLengthStreamingMode(requestBody.length);
    111111            connection.setDoOutput(true);
    112             final ProgressMonitor subTaskMonitor = progressMonitor.createSubTaskMonitor(1, false);
    113112            try (OutputStream out = new BufferedOutputStream(
    114                     new ProgressOutputStream(connection.getOutputStream(), requestBody.length, subTaskMonitor))) {
     113                    new ProgressOutputStream(connection.getOutputStream(), requestBody.length, progressMonitor))) {
    115114                out.write(requestBody);
    116115            }
     
    264263                in = connection.getErrorStream();
    265264            }
    266             monitor.subTask(tr("Fetching content..."));
    267265            if (in != null) {
    268                 in = new ProgressInputStream(in, getContentLength(), monitor.createSubTaskMonitor(1, false));
     266                in = new ProgressInputStream(in, getContentLength(), monitor);
    269267                in = "gzip".equalsIgnoreCase(getContentEncoding()) ? new GZIPInputStream(in) : in;
    270268                Compression compression = Compression.NONE;
Note: See TracChangeset for help on using the changeset viewer.