diff options
author | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2012-05-08 17:42:36 +0000 |
---|---|---|
committer | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2012-05-08 17:42:36 +0000 |
commit | 3c47f9e73bb3e052ea89c52f8e12f756a8cea027 (patch) | |
tree | 389168bdc816898d571b8b6efddcc5189ecf4cf6 /epan/dissectors/packet-hdfs.c | |
parent | c16cd8f997cc0b2b7a909e57fe906d39028a8a89 (diff) |
Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=42513
Diffstat (limited to 'epan/dissectors/packet-hdfs.c')
-rw-r--r-- | epan/dissectors/packet-hdfs.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/epan/dissectors/packet-hdfs.c b/epan/dissectors/packet-hdfs.c index 39a9635102..3a7de7aade 100644 --- a/epan/dissectors/packet-hdfs.c +++ b/epan/dissectors/packet-hdfs.c @@ -232,7 +232,7 @@ dissect_data (tvbuff_t *tvb, proto_tree *hdfs_tree, guint offset) { response to a get protocol version message contains a type length, type name and the value */ -static void +static int dissect_resp_long (tvbuff_t *tvb, proto_tree *hdfs_tree, int offset) { /* get length that we just dissected */ int length = tvb_get_ntohs(tvb, offset); @@ -247,13 +247,15 @@ dissect_resp_long (tvbuff_t *tvb, proto_tree *hdfs_tree, int offset) { /* the value */ proto_tree_add_item(hdfs_tree, hf_hdfs_prover, tvb, offset, 8, ENC_BIG_ENDIAN); - offset += 8; + offset += 8; + + return offset; } /* Response to a file status message */ -static void +static int dissect_resp_filestatus (tvbuff_t *tvb, proto_tree *hdfs_tree, int offset) { int length; @@ -324,6 +326,8 @@ dissect_resp_filestatus (tvbuff_t *tvb, proto_tree *hdfs_tree, int offset) { /* group name */ proto_tree_add_item(hdfs_tree, hf_hdfs_groupname, tvb, offset, length, ENC_ASCII|ENC_NA); offset += length; + + return offset; } @@ -598,7 +602,7 @@ dissect_hdfs_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) /* the value of the parameter */ proto_tree_add_item(hdfs_tree, hf_hdfs_paramval, tvb, offset, length, ENC_ASCII|ENC_NA); - offset += length; + /*offset += length;*/ } } @@ -618,7 +622,7 @@ dissect_hdfs_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) offset += 1; proto_tree_add_item(hdfs_tree, hf_hdfs_flags, tvb, offset, 1, ENC_BIG_ENDIAN); - offset += 1; + /*offset += 1;*/ } else { /* second authentication packet */ |