diff options
author | Anders Broman <anders.broman@ericsson.com> | 2013-05-14 19:57:19 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2013-05-14 19:57:19 +0000 |
commit | 8e509279b899720a94ffc466b49c0955222befe1 (patch) | |
tree | 546abfb2471636d97530060b6ad75c9cbf4f0515 /epan/exported_pdu.c | |
parent | cd01af1357a5587b22c4af3e43d82c27771add13 (diff) | |
download | wireshark-8e509279b899720a94ffc466b49c0955222befe1.tar.gz |
Add a tag for original frame number.
svn path=/trunk/; revision=49298
Diffstat (limited to 'epan/exported_pdu.c')
-rw-r--r-- | epan/exported_pdu.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/epan/exported_pdu.c b/epan/exported_pdu.c index 166797dd3f..9c66bb7323 100644 --- a/epan/exported_pdu.c +++ b/epan/exported_pdu.c @@ -83,6 +83,10 @@ load_export_pdu_tags(packet_info *pinfo, const char* proto_name, int wtap_encap tag_buf_size= tag_buf_size + EXP_PDU_TAG_DST_PORT_LEN + 4; } + if((tags_bit_field & EXP_PDU_TAG_ORIG_FNO_BIT) == EXP_PDU_TAG_ORIG_FNO_BIT){ + tag_buf_size= tag_buf_size + EXP_PDU_TAG_ORIG_FNO_LEN + 4; + } + /* Add end of options length */ tag_buf_size+=4; @@ -182,6 +186,22 @@ load_export_pdu_tags(packet_info *pinfo, const char* proto_name, int wtap_encap exp_pdu_data->tlv_buffer[i+1] = (pinfo->destport & 0x00ff0000) >> 16; exp_pdu_data->tlv_buffer[i+2] = (pinfo->destport & 0x0000ff00) >> 8; exp_pdu_data->tlv_buffer[i+3] = (pinfo->destport & 0x000000ff); + i = i +EXP_PDU_TAG_DST_PORT_LEN; + } + + if((tags_bit_field & EXP_PDU_TAG_ORIG_FNO_LEN) == EXP_PDU_TAG_ORIG_FNO_LEN){ + exp_pdu_data->tlv_buffer[i] = 0; + i++; + exp_pdu_data->tlv_buffer[i] = EXP_PDU_TAG_ORIG_FNO; + i++; + exp_pdu_data->tlv_buffer[i] = 0; + i++; + exp_pdu_data->tlv_buffer[i] = EXP_PDU_TAG_ORIG_FNO_LEN; /* tag length */ + i++; + exp_pdu_data->tlv_buffer[i] = (pinfo->fd->num & 0xff000000) >> 24; + exp_pdu_data->tlv_buffer[i+1] = (pinfo->fd->num & 0x00ff0000) >> 16; + exp_pdu_data->tlv_buffer[i+2] = (pinfo->fd->num & 0x0000ff00) >> 8; + exp_pdu_data->tlv_buffer[i+3] = (pinfo->fd->num & 0x000000ff); /*i = i +EXP_PDU_TAG_DST_PORT_LEN;*/ } |