[jenkins] 19/22: io-compat.pach
James Downing Page
jamespage at alioth.debian.org
Tue Aug 13 11:47:03 UTC 2013
This is an automated email from the git hooks/post-receive script.
jamespage pushed a commit to branch patch-queue/master
in repository jenkins.
commit 4b81fa65c13f938f4ae8aaccdaaba89e1d344e10
Author: Debian Java Maintainers <pkg-java-maintainers at lists.alioth.debian.org>
Date: Sun Aug 11 10:41:39 2013 +0100
io-compat.pach
Gbp-Pq-Topic: build
---
core/src/main/java/hudson/util/IOUtils.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/core/src/main/java/hudson/util/IOUtils.java b/core/src/main/java/hudson/util/IOUtils.java
index 4d046b7..240fda9 100644
--- a/core/src/main/java/hudson/util/IOUtils.java
+++ b/core/src/main/java/hudson/util/IOUtils.java
@@ -76,16 +76,18 @@ public class IOUtils extends org.apache.commons.io.IOUtils {
*
* @since 1.349
*/
- public static InputStream skip(InputStream in, long size) throws IOException {
+ public static long skip(InputStream in, long size) throws IOException {
DataInputStream di = new DataInputStream(in);
+ long skipped = 0;
while (size>0) {
int chunk = (int)Math.min(SKIP_BUFFER.length,size);
di.readFully(SKIP_BUFFER,0,chunk);
size -= chunk;
+ skipped += chunk;
}
- return in;
+ return skipped;
}
/**
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/jenkins.git
More information about the pkg-java-commits
mailing list