Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP4:FactoryCandidates
eclipse-jgit
jgit-5.11.0-java8.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File jgit-5.11.0-java8.patch of Package eclipse-jgit
diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlock.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlock.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlock.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlock.java 2021-07-30 11:47:47.425624542 +0200 @@ -13,6 +13,7 @@ package org.eclipse.jgit.internal.storage.dfs; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.util.zip.CRC32; import java.util.zip.DataFormatException; @@ -40,7 +41,7 @@ ByteBuffer zeroCopyByteBuffer(int n) { ByteBuffer b = ByteBuffer.wrap(block); - b.position(n); + ((Buffer)b).position(n); return b; } diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java 2021-07-30 11:47:47.425624542 +0200 @@ -21,6 +21,7 @@ import java.io.EOFException; import java.io.IOException; import java.io.InputStream; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.nio.channels.Channels; import java.text.MessageFormat; @@ -379,7 +380,7 @@ // Need to skip the 'PACK' header for the first read int ptr = packHeadSkipped ? 0 : 12; - buf.position(0); + ((Buffer)buf).position(0); int bufLen = read(rc, buf); if (bufLen <= ptr) { throw packfileIsTruncated(); diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReftable.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReftable.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReftable.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReftable.java 2021-07-30 11:47:47.425624542 +0200 @@ -13,6 +13,7 @@ import static org.eclipse.jgit.internal.storage.pack.PackExt.REFTABLE; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import org.eclipse.jgit.internal.storage.io.BlockSource; @@ -102,7 +103,7 @@ byte[] dst = new byte[cnt]; ByteBuffer buf = ByteBuffer.wrap(dst); - buf.position(ctx.copy(file, pos, dst, 0, cnt)); + ((Buffer)buf).position(ctx.copy(file, pos, dst, 0, cnt)); return buf; } diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/ByteBufferWindow.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/ByteBufferWindow.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/ByteBufferWindow.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/ByteBufferWindow.java 2021-07-30 11:47:47.425624542 +0200 @@ -13,6 +13,7 @@ package org.eclipse.jgit.internal.storage.file; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.util.zip.DataFormatException; import java.util.zip.Inflater; @@ -36,7 +37,7 @@ @Override protected int copy(int p, byte[] b, int o, int n) { final ByteBuffer s = buffer.slice(); - s.position(p); + ((Buffer)s).position(p); n = Math.min(s.remaining(), n); s.get(b, o, n); return n; @@ -46,7 +47,7 @@ void write(PackOutputStream out, long pos, int cnt) throws IOException { final ByteBuffer s = buffer.slice(); - s.position((int) (pos - start)); + ((Buffer)s).position((int) (pos - start)); while (0 < cnt) { byte[] buf = out.getCopyBuffer(); @@ -62,7 +63,7 @@ protected int setInput(int pos, Inflater inf) throws DataFormatException { final ByteBuffer s = buffer.slice(); - s.position(pos); + ((Buffer)s).position(pos); final byte[] tmp = new byte[Math.min(s.remaining(), 512)]; s.get(tmp, 0, tmp.length); inf.setInput(tmp, 0, tmp.length); diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/BlockReader.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/BlockReader.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/BlockReader.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/BlockReader.java 2021-07-30 11:47:47.425624542 +0200 @@ -31,6 +31,7 @@ import static org.eclipse.jgit.lib.Ref.Storage.PACKED; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.util.Arrays; import java.util.zip.DataFormatException; @@ -272,7 +273,7 @@ buf = b.array(); } else { buf = new byte[bufLen]; - b.flip(); + ((Buffer)b).flip(); b.get(buf); } endPosition = pos + bufLen; diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/ReftableReader.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/ReftableReader.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/ReftableReader.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/reftable/ReftableReader.java 2021-07-30 11:47:47.425624542 +0200 @@ -23,6 +23,7 @@ import static org.eclipse.jgit.lib.Constants.OBJECT_ID_LENGTH; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.text.MessageFormat; import java.util.Arrays; @@ -341,7 +342,7 @@ } byte[] tmp = new byte[len]; - buf.flip(); + ((Buffer)buf).flip(); buf.get(tmp); if (!isFileHeaderMagic(tmp, 0, len)) { throw new IOException(JGitText.get().invalidReftableFile); @@ -408,7 +409,7 @@ buf = tmp.array(); } else { buf = new byte[sz]; - tmp.flip(); + ((Buffer)tmp).flip(); tmp.get(buf); } if (pos == 0 && buf[FILE_HEADER_LEN] == FILE_BLOCK_TYPE) { diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/transport/RefAdvertiser.java 2021-07-30 11:47:47.425624542 +0200 @@ -17,6 +17,7 @@ import static org.eclipse.jgit.transport.GitProtocolConstants.REF_ATTR_SYMREF_TARGET; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.nio.CharBuffer; import java.nio.charset.CharacterCodingException; @@ -67,7 +68,7 @@ throws IOException { id.copyTo(binArr, 0); binArr[OBJECT_ID_STRING_LENGTH] = ' '; - binBuf.position(OBJECT_ID_STRING_LENGTH + 1); + ((Buffer)binBuf).position(OBJECT_ID_STRING_LENGTH + 1); append(refName); if (first) { first = false; @@ -90,7 +91,7 @@ chBuf = CharBuffer.wrap(chArr); } str.getChars(0, n, chArr, 0); - chBuf.position(0).limit(n); + ((Buffer)chBuf).position(0).limit(n); utf8.reset(); for (;;) { CoderResult cr = utf8.encode(chBuf, binBuf, true); @@ -117,7 +118,7 @@ System.arraycopy(binArr, 0, tmp, 0, cnt); binArr = tmp; binBuf = ByteBuffer.wrap(binArr); - binBuf.position(cnt); + ((Buffer)binBuf).position(cnt); } @Override diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/util/RawParseUtils.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/util/RawParseUtils.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit/src/org/eclipse/jgit/util/RawParseUtils.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit/src/org/eclipse/jgit/util/RawParseUtils.java 2021-07-30 11:47:47.425624542 +0200 @@ -18,6 +18,7 @@ import static org.eclipse.jgit.lib.ObjectChecker.encoding; import static org.eclipse.jgit.lib.ObjectChecker.tagger; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.nio.charset.CharacterCodingException; import java.nio.charset.Charset; @@ -1137,7 +1138,7 @@ final byte[] buffer, final int start, final int end) throws CharacterCodingException { ByteBuffer b = ByteBuffer.wrap(buffer, start, end - start); - b.mark(); + ((Buffer)b).mark(); // Try our built-in favorite. The assumption here is that // decoding will fail if the data is not actually encoded @@ -1145,7 +1146,7 @@ try { return decode(b, UTF_8); } catch (CharacterCodingException e) { - b.reset(); + ((Buffer)b).reset(); } if (!cs.equals(UTF_8)) { @@ -1154,7 +1155,7 @@ try { return decode(b, cs); } catch (CharacterCodingException e) { - b.reset(); + ((Buffer)b).reset(); } } @@ -1165,7 +1166,7 @@ try { return decode(b, defcs); } catch (CharacterCodingException e) { - b.reset(); + ((Buffer)b).reset(); } } diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectDownloadListener.java 2021-07-30 11:47:47.425624542 +0200 @@ -10,6 +10,7 @@ package org.eclipse.jgit.lfs.server.fs; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.nio.channels.Channels; import java.nio.channels.ReadableByteChannel; @@ -85,11 +86,11 @@ public void onWritePossible() throws IOException { while (out.isReady()) { try { - buffer.clear(); + ((Buffer)buffer).clear(); if (in.read(buffer) < 0) { buffer = null; } else { - buffer.flip(); + ((Buffer)buffer).flip(); } } catch (Throwable t) { LOG.log(Level.SEVERE, t.getMessage(), t); diff -urEbwB jgit-5.11.0.202103091610-r/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectUploadListener.java jgit-5.11.0.202103091610-r.new/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectUploadListener.java --- jgit-5.11.0.202103091610-r/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectUploadListener.java 2021-03-09 22:10:22.000000000 +0100 +++ jgit-5.11.0.202103091610-r.new/org.eclipse.jgit.lfs.server/src/org/eclipse/jgit/lfs/server/fs/ObjectUploadListener.java 2021-07-30 11:47:47.425624542 +0200 @@ -11,6 +11,7 @@ import java.io.FileNotFoundException; import java.io.IOException; +import java.nio.Buffer; import java.nio.ByteBuffer; import java.nio.channels.Channels; import java.nio.channels.ReadableByteChannel; @@ -131,11 +132,11 @@ public void onDataAvailable() throws IOException { while (in.isReady()) { if (inChannel.read(buffer) > 0) { - buffer.flip(); + ((Buffer)buffer).flip(); uploaded += Integer.valueOf(channel.write(buffer)).longValue(); buffer.compact(); } else { - buffer.flip(); + ((Buffer)buffer).flip(); while (buffer.hasRemaining()) { uploaded += Integer.valueOf(channel.write(buffer)) .longValue();
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor