mirror of
https://github.com/zeldaret/tp
synced 2026-05-22 22:44:28 -04:00
Fix dMsgFlow_c::event027 aParam8 buffer size (#3153)
This commit is contained in:
@@ -2229,7 +2229,13 @@ int dMsgFlow_c::event027(mesg_flow_node_event* i_flowNode_p, fopAc_ac_c* i_speak
|
||||
u16 prm0;
|
||||
getParam(&prm0, &prm1, i_flowNode_p->params);
|
||||
|
||||
// !@bug aParam8 is undersized; getParam always writes 4 bytes, stomping the
|
||||
// 2 bytes past the buffer. Harmless on GC/Wii (MWCC stack layout absorbs it).
|
||||
#if AVOID_UB
|
||||
u8 aParam8[4];
|
||||
#else
|
||||
u8 aParam8[2];
|
||||
#endif
|
||||
getParam(aParam8, i_flowNode_p->params);
|
||||
|
||||
JUT_ASSERT(4509, (aParam8[0] >= 0 && aParam8[0] <= dSv_player_item_c::BOMB_BAG_MAX) || (aParam8[0] == 4));
|
||||
|
||||
Reference in New Issue
Block a user