[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openbios
Subject:    [OpenBIOS] [commit] r1079 - trunk/openbios-devel/fs/hfsplus
From:       repository service <svn () openbios ! org>
Date:       2012-12-13 21:30:24
Message-ID: E1TjGMK-000060-2S () ra ! coresystems ! de
[Download RAW message or body]

Author: mcayland
Date: Thu Dec 13 22:30:23 2012
New Revision: 1079
URL: http://tracker.coreboot.org/trac/openbios/changeset/1079

Log:
mac-parts.c: Fix detection of wrapped HFS+ volumes.

The code for checking for a wrapped HFS+ volume looks at the wrong
offset. The offset of the magic number for the wrapped volume is 0x7c,
but vol is declared as a uint16 meaning the correct array index to
check is 0x3e (see
http://developer.apple.com/library/mac/#technotes/tn/tn1150.html).

Signed-off-by: William Hahne <will07c5@gmail.com>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>

Modified:
   trunk/openbios-devel/fs/hfsplus/hfsp_volume.c

Modified: trunk/openbios-devel/fs/hfsplus/hfsp_volume.c
==============================================================================
--- trunk/openbios-devel/fs/hfsplus/hfsp_volume.c	Sun Dec  9 21:37:53 2012	(r1078)
+++ trunk/openbios-devel/fs/hfsplus/hfsp_volume.c	Thu Dec 13 22:30:23 2012	(r1079)
@@ -311,7 +311,7 @@
 	os_read(fd, vol, 2, HFSP_BLOCKSZ_BITS);
 
 	if (__be16_to_cpu(vol[0]) == HFS_VOLHEAD_SIG &&
-		__be16_to_cpu(vol[0x7c]) == HFSP_VOLHEAD_SIG) {
+		__be16_to_cpu(vol[0x3e]) == HFSP_VOLHEAD_SIG) {
 		ret = -1;
 	} else if (__be16_to_cpu(vol[0]) == HFSP_VOLHEAD_SIG) {
 		ret = -1;

-- 
OpenBIOS                 http://openbios.org/
Mailinglist:  http://lists.openbios.org/mailman/listinfo
Free your System - May the Forth be with you
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic