(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/dissectors/packet-giop.c) |
| |
| 3702 | | | dissect_giop_locate_reply( tvbuff_t * tvb, packet_info * pinfo, |
| 3703 | | | proto_tree * tree, * , |
| 3704 | | | gboolean stream_is_big_endian) |
| 3705 | | | { |
| 3706 | | | guint32 offset = 0; |
| 3707 | | | guint32 request_id; |
| 3708 | | | guint32 locate_status; |
| 3709 | | | guint16 addr_disp; |
| 3710 | | | |
| 3711 | | | proto_tree *locate_reply_tree = NULL; |
| 3712 | | | proto_item *tf; |
| 3713 | | | |
| 3714 | | | if (tree) |
| 3715 | | | { |
| 3716 | | | tf = proto_tree_add_text (tree, tvb, offset, -1, |
| 3717 | | | "General Inter-ORB Locate Reply"); |
| 3718 | | | if (locate_reply_tree == NULL) |
| 3719 | | | { |
| 3720 | | | locate_reply_tree = proto_item_add_subtree (tf, ett_giop_locate_reply); |
| 3721 | | | |
| 3722 | | | } |
| 3723 | | | } |
| 3724 | | | |
| 3725 | | | request_id = get_CDR_ulong(tvb, &offset, stream_is_big_endian,); |
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 |
|
| 3726 | | | if (check_col(pinfo->cinfo, COL_INFO)) |
Event 2:
Skipping " if". check_col(...) evaluates to false.
hide
|
|
| 3727 | | | { |
| 3728 | | | col_append_fstr(pinfo->cinfo, COL_INFO, " id=%u", request_id); |
| 3729 | | | } |
| 3730 | | | if (locate_reply_tree) |
Event 3:
Skipping " if". locate_reply_tree evaluates to false.
hide
|
|
| 3731 | | | { |
| 3732 | | | proto_tree_add_text (locate_reply_tree, tvb, offset-4, 4, |
| 3733 | | | "Request id: %u", request_id); |
| 3734 | | | } |
| 3735 | | | |
| 3736 | | | locate_status = get_CDR_ulong(tvb, &offset, stream_is_big_endian,); |
| 3737 | | | if (locate_reply_tree) |
Event 4:
Skipping " if". locate_reply_tree evaluates to false.
hide
|
|
| 3738 | | | { |
| 3739 | | | proto_tree_add_text (locate_reply_tree, tvb, offset-4, 4, |
| 3740 | | | "Locate status: %s", |
| 3741 | | | val_to_str(locate_status, giop_locate_status_types, "(0x%x)") |
| 3742 | | | ); |
| 3743 | | | } |
| 3744 | | | |
| 3745 | | | |
| 3746 | | | |
| 3747 | | | |
| 3748 | | | |
| 3749 | | | |
| 3750 | | | |
| 3751 | | | |
| 3752 | | | if (->GIOP_version.minor > 1) {
x /usr/include/sys/sysmacros.h |
| |
66 | # define minor(dev) gnu_dev_minor (dev) |
| |
|
Event 5:
Taking true branch. ->GIOP_version.minor > 1 evaluates to true.
hide
|
|
| 3753 | | | while( ( (offset + ) % 8) != 0) |
| 3754 | | | ++(offset); |
| 3755 | | | } |
| 3756 | | | |
| 3757 | | | switch(locate_status) { |
Event 7:
locate_status evaluates to 5.
hide
|
|
| 3758 | | | case OBJECT_FORWARD: |
| 3759 | | | case OBJECT_FORWARD_PERM: |
| 3760 | | | decode_IOR(tvb, pinfo, locate_reply_tree, &offset, , stream_is_big_endian); |
| 3761 | | | break; |
| 3762 | | | case LOC_SYSTEM_EXCEPTION: |
| 3763 | | | decode_SystemExceptionReplyBody (tvb, tree, &offset, stream_is_big_endian, ); |
| 3764 | | | break; |
| 3765 | | | case LOC_NEEDS_ADDRESSING_MODE: |
| 3766 | | | addr_disp = get_CDR_ushort(tvb, &offset, stream_is_big_endian,); |
| 3767 | | | if(locate_reply_tree) { |
Event 8:
Skipping " if". locate_reply_tree evaluates to false.
hide
|
|
| 3768 | | | proto_tree_add_text (tree, tvb, offset -2, 2, |
| 3769 | | | "AddressingDisposition: %u", addr_disp); |
| 3770 | | | } |
| 3771 | | | break; |
| 3772 | | | default: |
| 3773 | | | break; |
| 3774 | | | } |
| 3775 | | | |
| 3776 | | | } |
| |