When writing the MBR, don't overwrite disk signature and the reserved word.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25088 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
ccce5afa3c
commit
7b51470a32
@ -254,11 +254,11 @@ LegacyBootDrive::ReadPartitions(BMessage *settings)
|
|||||||
off_t size = sizeof(kBootLoader);
|
off_t size = sizeof(kBootLoader);
|
||||||
if (!recorder.HasPartitions() || recorder.FirstOffset() < size)
|
if (!recorder.HasPartitions() || recorder.FirstOffset() < size)
|
||||||
return kErrorBootSectorTooSmall;
|
return kErrorBootSectorTooSmall;
|
||||||
|
|
||||||
|
// TODO remove when booting from all drives works
|
||||||
|
break;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO remove when booting from all drives works
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#if USE_SECOND_DISK
|
#if USE_SECOND_DISK
|
||||||
@ -514,7 +514,8 @@ void
|
|||||||
LegacyBootDrive::_CopyPartitionTable(MasterBootRecord* destination,
|
LegacyBootDrive::_CopyPartitionTable(MasterBootRecord* destination,
|
||||||
const MasterBootRecord* source)
|
const MasterBootRecord* source)
|
||||||
{
|
{
|
||||||
memcpy(destination->partition, source->partition, sizeof(source->partition));
|
memcpy(destination->diskSignature, source->diskSignature,
|
||||||
|
sizeof(source->diskSignature) + sizeof(source->reserved) + sizeof(source->partition));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user