aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-nbd.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2013-06-14 17:49:53 +0000
committerMichael Mann <mmann78@netscape.net>2013-06-14 17:49:53 +0000
commitde68fd6eea9996ca8572220f379e376acd0181e2 (patch)
treec874b6fd18d5b571366c0e3017b58e1fb73f3266 /epan/dissectors/packet-nbd.c
parent14b65f91a44b89ef460df391717b2a6ac317980d (diff)
Removed check_col() and the occasional tree.
svn path=/trunk/; revision=49938
Diffstat (limited to 'epan/dissectors/packet-nbd.c')
-rw-r--r--epan/dissectors/packet-nbd.c26
1 files changed, 11 insertions, 15 deletions
diff --git a/epan/dissectors/packet-nbd.c b/epan/dissectors/packet-nbd.c
index 3ca16d287a..ccc6e64f1f 100644
--- a/epan/dissectors/packet-nbd.c
+++ b/epan/dissectors/packet-nbd.c
@@ -332,18 +332,16 @@ dissect_nbd_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
proto_tree_add_item(tree, hf_nbd_len, tvb, offset, 4, ENC_BIG_ENDIAN);
offset+=4;
- if(check_col(pinfo->cinfo, COL_INFO)){
- switch(nbd_trans->type){
- case NBD_CMD_WRITE:
- col_add_fstr(pinfo->cinfo, COL_INFO, "Write Request Offset:0x%" G_GINT64_MODIFIER "x Length:%d", from, nbd_trans->datalen);
- break;
- case NBD_CMD_READ:
- col_add_fstr(pinfo->cinfo, COL_INFO, "Read Request Offset:0x%" G_GINT64_MODIFIER "x Length:%d", from, nbd_trans->datalen);
- break;
- case NBD_CMD_DISC:
- col_set_str(pinfo->cinfo, COL_INFO, "Disconnect Request");
- break;
- }
+ switch(nbd_trans->type){
+ case NBD_CMD_WRITE:
+ col_add_fstr(pinfo->cinfo, COL_INFO, "Write Request Offset:0x%" G_GINT64_MODIFIER "x Length:%d", from, nbd_trans->datalen);
+ break;
+ case NBD_CMD_READ:
+ col_add_fstr(pinfo->cinfo, COL_INFO, "Read Request Offset:0x%" G_GINT64_MODIFIER "x Length:%d", from, nbd_trans->datalen);
+ break;
+ case NBD_CMD_DISC:
+ col_set_str(pinfo->cinfo, COL_INFO, "Disconnect Request");
+ break;
}
if(nbd_trans->type==NBD_CMD_WRITE){
@@ -361,9 +359,7 @@ dissect_nbd_tcp_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
proto_tree_add_item(tree, hf_nbd_handle, tvb, offset, 8, ENC_BIG_ENDIAN);
offset+=8;
- if(check_col(pinfo->cinfo, COL_INFO)){
- col_add_fstr(pinfo->cinfo, COL_INFO, "%s Response Error:%d", (nbd_trans->type==NBD_CMD_WRITE)?"Write":"Read", error);
- }
+ col_add_fstr(pinfo->cinfo, COL_INFO, "%s Response Error:%d", (nbd_trans->type==NBD_CMD_WRITE)?"Write":"Read", error);
if(nbd_trans->type==NBD_CMD_READ){
proto_tree_add_item(tree, hf_nbd_data, tvb, offset, nbd_trans->datalen, ENC_NA);