From f2c275b1a76030d4c27ff124ce89e090f6aea584 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Thu, 16 Jun 2016 20:36:51 +0200 Subject: log download failure caused by missing content length --- src/main/java/eu/siacs/conversations/http/HttpDownloadConnection.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/java/eu/siacs/conversations') diff --git a/src/main/java/eu/siacs/conversations/http/HttpDownloadConnection.java b/src/main/java/eu/siacs/conversations/http/HttpDownloadConnection.java index c46f2b977..6f141aa86 100644 --- a/src/main/java/eu/siacs/conversations/http/HttpDownloadConnection.java +++ b/src/main/java/eu/siacs/conversations/http/HttpDownloadConnection.java @@ -224,7 +224,7 @@ public class HttpDownloadConnection implements Transferable { String contentLength = connection.getHeaderField("Content-Length"); connection.disconnect(); if (contentLength == null) { - throw new IOException(); + throw new IOException("no content-length found in HEAD response"); } wakeLock.release(); return Long.parseLong(contentLength, 10); -- cgit v1.2.3