|
|
@ -124,13 +124,18 @@ public class ObjectDownloadListener implements WriteListener { |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
buffer.flip(); |
|
|
|
buffer.flip(); |
|
|
|
} |
|
|
|
} |
|
|
|
} catch(Throwable t) { |
|
|
|
} catch (Throwable t) { |
|
|
|
LOG.log(Level.SEVERE, t.getMessage(), t); |
|
|
|
LOG.log(Level.SEVERE, t.getMessage(), t); |
|
|
|
buffer = null; |
|
|
|
buffer = null; |
|
|
|
} finally { |
|
|
|
} finally { |
|
|
|
if (buffer != null) { |
|
|
|
if (buffer != null) { |
|
|
|
outChannel.write(buffer); |
|
|
|
outChannel.write(buffer); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
in.close(); |
|
|
|
|
|
|
|
} catch (IOException e) { |
|
|
|
|
|
|
|
LOG.log(Level.SEVERE, e.getMessage(), e); |
|
|
|
|
|
|
|
} |
|
|
|
try { |
|
|
|
try { |
|
|
|
out.close(); |
|
|
|
out.close(); |
|
|
|
} finally { |
|
|
|
} finally { |
|
|
|