|
From: <ga...@us...> - 2011-11-30 20:49:04
|
Revision: 5869
http://jnode.svn.sourceforge.net/jnode/?rev=5869&view=rev
Author: galatnm
Date: 2011-11-30 20:48:58 +0000 (Wed, 30 Nov 2011)
Log Message:
-----------
Fix HFS+ catalog key from luke.
Modified Paths:
--------------
trunk/fs/src/fs/org/jnode/fs/hfsplus/catalog/CatalogKey.java
Modified: trunk/fs/src/fs/org/jnode/fs/hfsplus/catalog/CatalogKey.java
===================================================================
--- trunk/fs/src/fs/org/jnode/fs/hfsplus/catalog/CatalogKey.java 2011-11-30 20:48:12 UTC (rev 5868)
+++ trunk/fs/src/fs/org/jnode/fs/hfsplus/catalog/CatalogKey.java 2011-11-30 20:48:58 UTC (rev 5869)
@@ -44,11 +44,12 @@
* @param src
* @param offset
*/
+
public CatalogKey(final byte[] src, final int offset) {
int currentOffset = offset;
byte[] ck = new byte[2];
System.arraycopy(src, currentOffset, ck, 0, 2);
- keyLength = BigEndian.getInt16(ck, 0);
+ keyLength = BigEndian.getInt16(ck, 0) + 2; // Key length doesn't seem to include itself in the size
currentOffset += 2;
ck = new byte[4];
System.arraycopy(src, currentOffset, ck, 0, 4);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|