From ba233e87efddf0a6751b35784dca1c805364ff3b Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 11 Feb 2015 13:20:49 +0200 Subject: remove unnecessary parenthesis in return statements found with $ git grep -lP 'return\s*\(\s*\w+\s*\)\s*;' Change-Id: Ic51606877a9edcadeb647c5bf17bc928b69ab60e --- .../lib/uno/adapter/InputStreamToXInputStreamAdapter.java | 6 +++--- .../lib/uno/adapter/XInputStreamToInputStreamAdapter.java | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'javaunohelper/com') diff --git a/javaunohelper/com/sun/star/lib/uno/adapter/InputStreamToXInputStreamAdapter.java b/javaunohelper/com/sun/star/lib/uno/adapter/InputStreamToXInputStreamAdapter.java index feaca77cc9a6..0053c4dfee70 100644 --- a/javaunohelper/com/sun/star/lib/uno/adapter/InputStreamToXInputStreamAdapter.java +++ b/javaunohelper/com/sun/star/lib/uno/adapter/InputStreamToXInputStreamAdapter.java @@ -59,7 +59,7 @@ public final class InputStreamToXInputStreamAdapter implements XInputStream { throw new com.sun.star.io.IOException(e); } - return(bytesAvail); + return bytesAvail; } public void closeInput() throws @@ -88,7 +88,7 @@ public final class InputStreamToXInputStreamAdapter implements XInputStream { // must <= len. if (bytesRead <= 0) { - return(0); + return 0; } return ((int)bytesRead); @@ -114,7 +114,7 @@ public final class InputStreamToXInputStreamAdapter implements XInputStream { // must <= len. if (bytesRead <= 0) { - return(0); + return 0; } return ((int)bytesRead); diff --git a/javaunohelper/com/sun/star/lib/uno/adapter/XInputStreamToInputStreamAdapter.java b/javaunohelper/com/sun/star/lib/uno/adapter/XInputStreamToInputStreamAdapter.java index c77c57b5adc1..978d10f6a5a6 100644 --- a/javaunohelper/com/sun/star/lib/uno/adapter/XInputStreamToInputStreamAdapter.java +++ b/javaunohelper/com/sun/star/lib/uno/adapter/XInputStreamToInputStreamAdapter.java @@ -60,7 +60,7 @@ public final class XInputStreamToInputStreamAdapter extends InputStream { throw newEx; } - return(bytesAvail); + return bytesAvail; } @Override @@ -87,7 +87,7 @@ public final class XInputStreamToInputStreamAdapter extends InputStream { if (tmpInt< 0 ){ tmpInt = 256 +tmpInt; } - return(tmpInt); + return tmpInt; } } catch (Exception e) { @@ -106,7 +106,7 @@ public final class XInputStreamToInputStreamAdapter extends InputStream { try { bytesRead = xin.readBytes(tmp, b.length); if (bytesRead <= 0) { - return(-1); + return -1; } else if (bytesRead < b.length) { System.arraycopy(tmp[0], 0, b, 0, bytesRead); } else { @@ -138,7 +138,7 @@ public final class XInputStreamToInputStreamAdapter extends InputStream { // must <= len. if (bytesRead <= 0) { - return(-1); + return -1; } else if (bytesRead < len) { System.arraycopy(tmp[0], 0, b, off, (int)bytesRead); } else { @@ -187,9 +187,9 @@ public final class XInputStreamToInputStreamAdapter extends InputStream { } while (tmpLongVal > 0); if ( avail != 0 && avail < n) { - return(avail); + return avail; } else { - return(n); + return n; } } -- cgit