Remove BlockChange from packed structs

pragma pack (push, 1) forces alignment to 1-byte.
While reordering the fields does help with memory accesses, it only
works if the compiler can ensure 2-byte alignments for this struct.
This commit is contained in:
Mefiresu
2025-09-12 20:06:48 +02:00
committed by p2r3
parent ba03d92ad0
commit 808bbb26a2

View File

@@ -172,8 +172,6 @@ extern uint8_t motd_len;
extern uint16_t client_count;
#pragma pack(push, 1)
typedef struct {
short x;
short z;
@@ -181,6 +179,8 @@ typedef struct {
uint8_t block;
} BlockChange;
#pragma pack(push, 1)
typedef struct {
uint8_t uuid[16];
char name[16];