(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/dissectors/packet-nhrp.c) |
| |
| 833 | | | void dissect_nhrp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) |
| 834 | | | { |
| 835 | | | e_nhrp_hdr hdr; |
| 836 | | | gint mandLen = 0; |
| 837 | | | gint extLen = 0; |
| 838 | | | gint offset = 0; |
| 839 | | | proto_item *ti = NULL; |
| 840 | | | proto_tree *nhrp_tree = NULL; |
| 841 | | | oui_info_t *oui_info; |
| 842 | | | |
| 843 | [+] | | if (check_col(pinfo->cinfo, COL_PROTOCOL)) { |
 |
| 844 | | | col_set_str(pinfo->cinfo, COL_PROTOCOL, "NHRP"); |
| 845 | | | } |
| 846 | [+] | | if (check_col(pinfo->cinfo, COL_INFO)) { |
 |
| 847 | | | col_clear(pinfo->cinfo, COL_INFO); |
| 848 | | | } |
| 849 | | | |
| 850 | | | memset(&hdr, 0, sizeof(e_nhrp_hdr)); |
| 851 | | | |
| 852 | | | hdr.ar_op_type = tvb_get_guint8(tvb, 17); |
| 853 | | | |
| 854 | [+] | | if (check_col(pinfo->cinfo, COL_INFO)) { |
 |
| 855 | | | col_add_str(pinfo->cinfo, COL_INFO, |
| 856 | | | val_to_str(hdr.ar_op_type, nhrp_op_type_vals, |
| 857 | | | "0x%02X - unknown")); |
| 858 | | | } |
| 859 | | | col_set_writable(pinfo->cinfo, FALSE); |
| 860 | | | |
| 861 | | | ti = proto_tree_add_protocol_format(tree, proto_nhrp, tvb, 0, -1, |
| 862 | | | "Next Hop Resolution Protocol (%s)", |
| 863 | | | val_to_str(hdr.ar_op_type, nhrp_op_type_vals, "0x%02X - unknown")); |
| 864 | | | nhrp_tree = proto_item_add_subtree(ti, ett_nhrp); |
| 865 | | | |
| 866 | | | dissect_nhrp_hdr(tvb, pinfo, nhrp_tree, &offset, &mandLen, &extLen, |
| 867 | [+] | | &oui_info, &hdr); |
Event 7:
dissect_nhrp_hdr() does not initialize oui_info. - This may be because of a failure case or other special case for dissect_nhrp_hdr().
hide
|
|
 |
| 868 | | | if (mandLen) { |
Event 17:
Taking true branch. mandLen evaluates to true.
hide
|
|
| 869 | | | dissect_nhrp_mand(tvb, pinfo, nhrp_tree, &offset, mandLen, |
| 870 | | | oui_info, &hdr); |
Uninitialized Variable
oui_info was not initialized. The issue can occur if the highlighted code executes. See related event 7. Show: All events | Only primary events |
|
| |