diff options
author | Haru <haru@dotalux.com> | 2015-05-19 01:59:33 +0200 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2015-05-19 03:08:22 +0200 |
commit | bd2109d614a443045c7bbbf632bb9035216e3623 (patch) | |
tree | 2e125e4ce2b6a8c60b5e2303b1e2b0a88386ff70 /src/map/status.h | |
parent | 6ac5a0ccfb601b81e1b84f6e86175d40bb16864b (diff) | |
download | hercules-bd2109d614a443045c7bbbf632bb9035216e3623.tar.gz hercules-bd2109d614a443045c7bbbf632bb9035216e3623.tar.bz2 hercules-bd2109d614a443045c7bbbf632bb9035216e3623.tar.xz hercules-bd2109d614a443045c7bbbf632bb9035216e3623.zip |
Fixed some issues reported by coverity scan [3/3]
- Automatically zeroed variables are now zeroed in the correct size,
regardless of padding.
- Special thanks to Ind.
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/map/status.h')
-rw-r--r-- | src/map/status.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/map/status.h b/src/map/status.h index 3b85c4014..b370a9c88 100644 --- a/src/map/status.h +++ b/src/map/status.h @@ -1980,7 +1980,8 @@ struct status_interface { /* vars */ int current_equip_item_index; int current_equip_card_id; - /* */ + +BEGIN_ZEROED_BLOCK; /* Everything within this block will be memset to 0 when status_defaults() is executed */ int max_weight_base[CLASS_COUNT]; int HP_table[CLASS_COUNT][MAX_LEVEL + 1]; int SP_table[CLASS_COUNT][MAX_LEVEL + 1]; @@ -1997,6 +1998,8 @@ struct status_interface { int atkmods[3][MAX_WEAPON_TYPE];//ATK weapon modification for size (size_fix.txt) char job_bonus[CLASS_COUNT][MAX_LEVEL]; sc_conf_type sc_conf[SC_MAX]; +END_ZEROED_BLOCK; /* End */ + struct eri *data_ers; //For sc_data entries struct status_data dummy; int64 natural_heal_prev_tick; |