code formatting

Signed-off-by: tobiasKaminsky <tobias@kaminsky.me>
This commit is contained in:
tobiasKaminsky 2018-11-09 13:17:12 +01:00
parent 6850d73c40
commit 959cce44fb
No known key found for this signature in database
GPG key ID: 0E00D4D47D0C5AF7

View file

@ -218,16 +218,17 @@ public class InputStreamBinder extends IInputStreamService.Stub {
StringBuilder total = new StringBuilder();
InputStream inputStream = method.getResponseBodyAsStream();
// If response body is available
if(inputStream != null) {
BufferedReader r = new BufferedReader(new InputStreamReader(inputStream));
String line = r.readLine();
while(line != null) {
if (inputStream != null) {
BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream));
String line = reader.readLine();
while (line != null) {
total.append(line).append('\n');
line = r.readLine();
line = reader.readLine();
}
Log_OC.e(TAG, total.toString());
}
throw new IllegalStateException(EXCEPTION_HTTP_REQUEST_FAILED, new IllegalStateException(String.valueOf(status), new Throwable(total.toString())));
throw new IllegalStateException(EXCEPTION_HTTP_REQUEST_FAILED,
new IllegalStateException(String.valueOf(status), new Throwable(total.toString())));
}
}