Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #define MAX_CCMS 4
- ccm_cfg_t ccm[MAX_CCMS];
- var_t prot_cfg_table[CFGID_PROTOCOL_MAX+1] = {
- ....
- {"ccmSrstIpAddr", CFGVAR(ccm[4].address), PA_STR, PR_STR, 0},
- {"ccmSrst_sipPort", CFGVAR(ccm[4].sip_port),PA_INT, PR_INT, 0},
- {"ccmSrst_isValid", CFGVAR(ccm[4].is_valid),PA_INT, PR_INT, 0},
- {"ccmSrst_securityLevel",
- CFGVAR(ccm[4].sec_level), PA_INT, PR_INT, 0},
- ....
- };
- This suspicious code was found in WebRTC project by PVS-Studio static code analyzer.
- Warning message is:
- V557 Array overrun is possible. The '4' index is pointing beyond array bound. prot_cfgmgr_private.h 357
- PVS-Studio is a static analyzer for detecting bugs in the source code of applications written in C, C++, C++11, C++/CX. Site: http://www.viva64.com/en/pvs-studio/
Advertisement
Add Comment
Please, Sign In to add comment