mirror of
https://github.com/RPCSX/llvm.git
synced 2025-02-03 02:53:06 +00:00
Fix alignment problem
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8707 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
03f252f1eb
commit
4eed793d5a
@ -97,7 +97,7 @@ BytecodeBufferReader::BytecodeBufferReader(const unsigned char *Buf,
|
||||
const unsigned char *ParseBegin = 0;
|
||||
if ((intptr_t)Buf & 3) {
|
||||
Buffer = new unsigned char[Length+4];
|
||||
unsigned Offset = 4 - ((intptr_t)Buf & 3); // Make sure it's aligned
|
||||
unsigned Offset = 4 - ((intptr_t)Buffer & 3); // Make sure it's aligned
|
||||
ParseBegin = Buffer + Offset;
|
||||
memcpy((unsigned char*)ParseBegin, Buf, Length); // Copy it over
|
||||
MustDelete = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user