(/home/sate/Testcases/c/cve/wireshark-1.2.0/plugins/giop/packet-cosnaming.c) |
| |
| 1117 | | | static void decode_CosNaming_NamingContext_list(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto_tree *tree _U_, int *offset _U_, *, gchar *operation _U_) { |
| 1118 | | | |
| 1119 | | | gboolean stream_is_big_endian; |
| 1120 | | | |
| 1121 | | | |
| 1122 | | | |
| 1123 | | | |
| 1124 | | | guint32 u_octet4; |
| 1125 | | | guint32 u_octet4_loop_bl; |
| 1126 | | | guint32 i_bl; |
| 1127 | | | |
| 1128 | | | |
| 1129 | | | |
| 1130 | | | |
| 1131 | | | stream_is_big_endian = is_big_endian(); |
| 1132 | | | |
| 1133 | | | switch(->message_type) { |
| 1134 | | | |
| 1135 | | | case Request: |
| 1136 | | | |
| 1137 | | | u_octet4 = get_CDR_ulong(tvb,offset,stream_is_big_endian, boundary); |
Ignored Return Value
The return value of get_CDR_ulong() is never checked in the highlighted execution scenario. - If the return value can indicate an error, the error will be ignored if the highlighted code executes.
- The return value of get_CDR_ulong() is checked 97% of the time in this project. CodeSonar is configured to enforce Ignored Return Value checks for any function whose return value is checked at least 96% of the time, unless the function is used fewer than 20 times. (To modify these thresholds, use configuration file parameters RETURN_CHECKER_SAMPLE_SIZE and RETURN_CHECKER_RATIO. To exempt get_CDR_ulong() from the Ignored Return Value check, use configuration file parameter RETURN_CHECKER_IGNORED_FUNCS).
Show: All events | Only primary events |
|
| 1138 | | | if (tree) { |
Event 2:
Skipping " if". tree evaluates to false.
hide
|
|
| 1139 | | | proto_tree_add_text(tree,tvb,*offset-4,4,"how_many = %u",u_octet4); |
| 1140 | | | } |
| 1141 | | | |
| 1142 | | | break; |
| 1143 | | | |
| 1144 | | | case Reply: |
| 1145 | | | |
| 1146 | | | switch(->rep_status) { |
| 1147 | | | |
| 1148 | | | case NO_EXCEPTION: |
| 1149 | | | |
| 1150 | | | |
| 1151 | | | |
| 1152 | | | |
| 1153 | | | |
| 1154 | | | u_octet4_loop_bl = get_CDR_ulong(tvb, offset, stream_is_big_endian, boundary); |
| 1155 | | | if (tree) { |
| 1156 | | | proto_tree_add_text(tree,tvb,*offset-4, 4 ,"Seq length of bl = %u",u_octet4_loop_bl); |
| 1157 | | | } |
| 1158 | | | |
| 1159 | | | for (i_bl=0; i_bl < u_octet4_loop_bl; i_bl++) { |
| 1160 | | | |
| 1161 | | | |
| 1162 | | | |
| 1163 | | | |
| 1164 | | | |
| 1165 | | | decode_CosNaming_Binding_st(tvb, pinfo, tree, offset, , operation); |
| 1166 | | | |
| 1167 | | | |
| 1168 | | | |
| 1169 | | | |
| 1170 | | | } |
| 1171 | | | |
| 1172 | | | get_CDR_object(tvb, pinfo, tree, offset, stream_is_big_endian, boundary); |
| 1173 | | | |
| 1174 | | | |
| 1175 | | | break; |
| 1176 | | | |
| 1177 | | | case USER_EXCEPTION: |
| 1178 | | | |
| 1179 | | | break; |
| 1180 | | | |
| 1181 | | | default: |
| 1182 | | | |
| 1183 | | | |
| 1184 | | | |
| 1185 | | | g_warning("Unknown Exception ");
x /usr/include/glib-2.0/glib/gmessages.h |
| |
153 | #define g_warning(...) g_log (G_LOG_DOMAIN, \ |
154 | G_LOG_LEVEL_WARNING, \ |
155 | __VA_ARGS__) |
| |
|
| 1186 | | | |
| 1187 | | | |
| 1188 | | | |
| 1189 | | | break; |
| 1190 | | | |
| 1191 | | | |
| 1192 | | | } |
| 1193 | | | |
| 1194 | | | break; |
| 1195 | | | |
| 1196 | | | default: |
| 1197 | | | |
| 1198 | | | |
| 1199 | | | |
| 1200 | | | g_warning("Unknown GIOP Message");
x /usr/include/glib-2.0/glib/gmessages.h |
| |
153 | #define g_warning(...) g_log (G_LOG_DOMAIN, \ |
154 | G_LOG_LEVEL_WARNING, \ |
155 | __VA_ARGS__) |
| |
|
| 1201 | | | |
| 1202 | | | |
| 1203 | | | break; |
| 1204 | | | |
| 1205 | | | |
| 1206 | | | } |
| 1207 | | | |
| 1208 | | | } |
| |