summaryrefslogtreecommitdiff
path: root/src/map/packets_struct.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/packets_struct.h')
-rw-r--r--src/map/packets_struct.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/map/packets_struct.h b/src/map/packets_struct.h
index b604c77b8..71f986a90 100644
--- a/src/map/packets_struct.h
+++ b/src/map/packets_struct.h
@@ -3819,9 +3819,15 @@ struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub {
uint32 index;
uint32 zeny;
uint32 currency_count;
- struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub2 currencies[];
+ // Workaround for fix Visual Studio bug (error C2233). Here should be currencies[]
+ struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub2 currencies[1];
} __attribute__((packed));
+// Workaround check for Visual Studio bug (error C2233)
+STATIC_ASSERT(sizeof(struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub2[1]) ==
+ sizeof(struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub2),
+ "Wrong PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub size");
+
struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN {
int16 packetType;
int16 packetLength;