|
|
0ffb03 |
diff -up wireshark-1.10.14/wiretap/pcapng.c.drop_count wireshark-1.10.14/wiretap/pcapng.c
|
|
|
0ffb03 |
--- wireshark-1.10.14/wiretap/pcapng.c.drop_count 2017-06-13 10:08:24.297419620 +0200
|
|
|
0ffb03 |
+++ wireshark-1.10.14/wiretap/pcapng.c 2017-06-13 11:33:46.264786204 +0200
|
|
|
0ffb03 |
@@ -3242,6 +3242,10 @@ pcapng_write_enhanced_packet_block(wtap_
|
|
|
0ffb03 |
have_options = TRUE;
|
|
|
0ffb03 |
options_total_length = options_total_length + 8;
|
|
|
0ffb03 |
}
|
|
|
0ffb03 |
+ if (phdr->presence_flags & WTAP_HAS_DROP_COUNT) {
|
|
|
0ffb03 |
+ have_options = TRUE;
|
|
|
0ffb03 |
+ options_total_length = options_total_length + 12;
|
|
|
0ffb03 |
+ }
|
|
|
0ffb03 |
if (have_options) {
|
|
|
0ffb03 |
/* End-of optios tag */
|
|
|
0ffb03 |
options_total_length += 4;
|
|
|
0ffb03 |
@@ -3364,6 +3368,17 @@ pcapng_write_enhanced_packet_block(wtap_
|
|
|
0ffb03 |
wdh->bytes_dumped += 4;
|
|
|
0ffb03 |
pcapng_debug1("pcapng_write_enhanced_packet_block: Wrote Options packet flags: %x", phdr->pack_flags);
|
|
|
0ffb03 |
}
|
|
|
0ffb03 |
+ if (phdr->presence_flags & WTAP_HAS_DROP_COUNT) {
|
|
|
0ffb03 |
+ option_hdr.type = OPT_EPB_DROPCOUNT;
|
|
|
0ffb03 |
+ option_hdr.value_length = 8;
|
|
|
0ffb03 |
+ if (!wtap_dump_file_write(wdh, &option_hdr, 4, err))
|
|
|
0ffb03 |
+ return FALSE;
|
|
|
0ffb03 |
+ wdh->bytes_dumped += 4;
|
|
|
0ffb03 |
+ if (!wtap_dump_file_write(wdh, &phdr->drop_count, 8, err))
|
|
|
0ffb03 |
+ return FALSE;
|
|
|
0ffb03 |
+ wdh->bytes_dumped += 8;
|
|
|
0ffb03 |
+ pcapng_debug1("pcapng_write_enhanced_packet_block: Wrote Options drop count: %" G_GINT64_MODIFIER "u", phdr->drop_count);
|
|
|
0ffb03 |
+ }
|
|
|
0ffb03 |
/* Write end of options if we have otions */
|
|
|
0ffb03 |
if (have_options) {
|
|
|
0ffb03 |
if (!wtap_dump_file_write(wdh, &zero_pad, 4, err))
|