Fix SIGBUS on some platforms. Memory alignment matters!

This is a temporary fix; I'm not convinced it will work on all platforms,
so I will probably end up removing all of the memory boundary code
altogether.
This commit is contained in:
Jordan Bancino 2023-05-26 23:05:35 +00:00
parent d24c1161f6
commit 34f33a1c1b
2 changed files with 3 additions and 3 deletions

View file

@ -50,8 +50,8 @@ struct MemoryInfo
void *pointer;
};
#define MEM_BOUND_TYPE UInt16
#define MEM_BOUND 0xFFFF
#define MEM_BOUND_TYPE UInt32
#define MEM_BOUND 0xFFFFFFFF
#define MEM_BOUND_LOWER(p) *((MEM_BOUND_TYPE *) p)
#define MEM_BOUND_UPPER(p, x) *(((MEM_BOUND_TYPE *) (((UInt8 *) p) + x)) + 1)

View file

@ -12,7 +12,7 @@ Milestone: v0.3.0
-----------------
[x] Fix leaks in json
[ ] Debug ARM64 Debian
[x] Debug ARM64 Debian
[ ] Cytoplasm
[ ] Debug OpenSSL