diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java index a76e13bdf..a5a8c56d9 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java @@ -358,6 +358,7 @@ public class DfsGarbageCollector { out = objdb.writeFile(pack, PACK); try { pw.writePack(pm, pm, out); + pack.addFileExt(PACK); } finally { out.close(); } @@ -366,6 +367,7 @@ public class DfsGarbageCollector { try { CountingOutputStream cnt = new CountingOutputStream(out); pw.writeIndex(cnt); + pack.addFileExt(INDEX); pack.setFileSize(INDEX, cnt.getCount()); pack.setIndexVersion(pw.getIndexVersion()); } finally { @@ -377,6 +379,7 @@ public class DfsGarbageCollector { try { CountingOutputStream cnt = new CountingOutputStream(out); pw.writeBitmapIndex(cnt); + pack.addFileExt(BITMAP_INDEX); pack.setFileSize(BITMAP_INDEX, cnt.getCount()); } finally { out.close(); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsInserter.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsInserter.java index 9f5ddbdd8..76554c0ad 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsInserter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsInserter.java @@ -153,6 +153,7 @@ public class DfsInserter extends ObjectInserter { throw new IOException(); byte[] packHash = packOut.writePackFooter(); + packDsc.addFileExt(PACK); packDsc.setFileSize(PACK, packOut.getCount()); packOut.close(); packOut = null; @@ -261,6 +262,7 @@ public class DfsInserter extends ObjectInserter { buf.writeTo(cnt, null); else index(cnt, packHash, list); + pack.addFileExt(INDEX); pack.setFileSize(INDEX, cnt.getCount()); } finally { os.close(); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackCompactor.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackCompactor.java index 926395c89..ddd6ff7c0 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackCompactor.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackCompactor.java @@ -289,6 +289,7 @@ public class DfsPackCompactor { DfsOutputStream out = objdb.writeFile(pack, PACK); try { pw.writePack(pm, pm, out); + pack.addFileExt(PACK); } finally { out.close(); } @@ -301,6 +302,7 @@ public class DfsPackCompactor { try { CountingOutputStream cnt = new CountingOutputStream(out); pw.writeIndex(cnt); + pack.addFileExt(INDEX); pack.setFileSize(INDEX, cnt.getCount()); pack.setIndexVersion(pw.getIndexVersion()); } finally { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackParser.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackParser.java index f394348b2..6430ea9c2 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackParser.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackParser.java @@ -148,6 +148,7 @@ public class DfsPackParser extends PackParser { out = null; currBuf = null; readBlock = null; + packDsc.addFileExt(PACK); packDsc.setFileSize(PACK, packEnd); writePackIndex();