Fix alignment when saving the branch value
This commit is contained in:
parent
aadf4edbed
commit
f9a1935c8e
2 changed files with 5 additions and 4 deletions
|
@ -1150,8 +1150,9 @@ static Bit8u * gen_create_branch_long(BranchTypes type) {
|
|||
return (cache.pos-4);
|
||||
}
|
||||
|
||||
static void gen_fill_branch_long(Bit8u * data,Bit8u * from=cache.pos) {
|
||||
*(Bit32u*)data=(Bit32u)(from-data-4);
|
||||
static void gen_fill_branch_long(uint8_t *data, uint8_t *from = cache.pos)
|
||||
{
|
||||
host_writed(data, from - data - sizeof(uint32_t));
|
||||
}
|
||||
|
||||
static Bit8u * gen_create_jump(Bit8u * to=0) {
|
||||
|
|
|
@ -983,8 +983,8 @@ static Bit8u * gen_create_branch_long(BranchTypes type) {
|
|||
return (cache.pos-4);
|
||||
}
|
||||
|
||||
static void gen_fill_branch_long(Bit8u * data,Bit8u * from=cache.pos) {
|
||||
*(Bit32u*)data=(from-data-4);
|
||||
static void gen_fill_branch_long(uint8_t *data, uint8_t *from = cache.pos) {
|
||||
host_writed(data, from - data - sizeof(uint32_t));
|
||||
}
|
||||
|
||||
static Bit8u * gen_create_jump(Bit8u * to=0) {
|
||||
|
|
Loading…
Add table
Reference in a new issue