ERROR TYPE: SIZEOF_MISMATCH MODULE SUPPORT LEVEL: core Generated on: 2012-04-10 12:02:08.349291 ------------------------------------------------ FINDING #0 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/main/db1-ast/hash/hash.c:915: suspicious_sizeof: Passing argument "sizeof (SEGMENT *) /*8*/" to function "calloc" and then casting the return value to "SEGMENT *" is suspicious. Did you intend to use "sizeof(SEGMENT)" instead of "sizeof (SEGMENT *)" ? In this particular case sizeof(SEGMENT *) happens to be equal to sizeof(SEGMENT), but this is not a portable assumption. FINDING #1 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/main/db1-ast/hash/hash.c:923: suspicious_sizeof: Passing argument "sizeof (SEGMENT) /*8*/" to function "calloc" and then casting the return value to "SEGMENT" is suspicious. Did you intend to use "sizeof(BUFHEAD *)" instead of "sizeof (SEGMENT)" ? In this particular case sizeof(SEGMENT) happens to be equal to sizeof(BUFHEAD *), but this is not a portable assumption. FINDING #2 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/main/channel.c:5675: suspicious_sizeof: Passing argument "from" of type "struct ast_channel *" and argument "sizeof (struct ast_channel *) /*8*/" to function "ast_channel_setoption" is suspicious. Did you intend to use "sizeof(struct ast_channel)" instead of "sizeof (struct ast_channel *)" ? FINDING #3 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/codecs/codec_g722.c:114: suspicious_pointer_arithmetic: Adding "pvt->samples * sizeof (int16_t) /*2*/" to pointer "pvt->outbuf.i16" of type "int16_t *" is suspicious because adding an integral value to this pointer automatically scales that value by the size, 2 bytes, of the pointed-to type, "int16_t". Most likely, the multiplication by "sizeof (int16_t)" in this expression is extraneous and should be eliminated. FINDING #4 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/main/db1-ast/hash/hash.c:839: suspicious_sizeof: Passing argument "sizeof (SEGMENT) /*8*/" to function "calloc" and then casting the return value to "SEGMENT" is suspicious. Did you intend to use "sizeof(BUFHEAD *)" instead of "sizeof (SEGMENT)" ? In this particular case sizeof(SEGMENT) happens to be equal to sizeof(BUFHEAD *), but this is not a portable assumption. FINDING #5 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/res/res_calendar_ews.c:236: suspicious_sizeof: Passing argument "sizeof (id) /*8*/" to function "_ast_calloc" and then casting the return value to "struct calendar_id *" is suspicious. Did you intend to use "sizeof(*id)" instead of "sizeof (id)" ? FINDING #6 [core]: /builddir/build/BUILD/asterisk-1.8.6.0/res/res_crypto.c:119: suspicious_sizeof: Passing argument "buf" of type "char *" and argument "sizeof (buf) /*8*/" to function "memset" is suspicious.