Wireshark-commits: [Wireshark-commits] master 1e76e13: wiretap: refactor common parameters for pcap
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=1e76e1355ab2cafba517a1ba556450ded397d885
Submitter: "Peter Wu <peter@xxxxxxxxxxxxx>"
Changed: branch: master
Repository: wireshark
Commits:
1e76e13 by Peter Wu (peter@xxxxxxxxxxxxx):
wiretap: refactor common parameters for pcapng dump routines
Four variants of wtap_dump_open_ng exists, each of them take the same
three parameters for the SHB, IDB and NRB blocks that has to be written
before packets are even written. Similarly, a lot of tools always create
these arguments based on an existing capture file session (wth).
Address the former duplication by creating a new data structure to hold
the arguments. Address the second issue by creating new helper functions
to initialize the parameters based on a wth. This refactoring should
make it easier to add the new Decryption Secrets Block (DSB).
No functional change intended.
Change-Id: I42c019dc1d48a476773459212ca213de91a55684
Reviewed-on: https://code.wireshark.org/review/30578
Petri-Dish: Peter Wu <peter@xxxxxxxxxxxxx>
Petri-Dish: Guy Harris <guy@xxxxxxxxxxxx>
Tested-by: Petri Dish Buildbot
Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
Actions performed:
from 791a9a9 Remove obsolete files.
add 1e76e13 wiretap: refactor common parameters for pcapng dump routines
Summary of changes:
debian/libwiretap0.symbols | 2 +
editcap.c | 34 +++++++----------
file.c | 38 ++++++++-----------
reordercap.c | 25 +++++--------
tshark.c | 49 ++++++++++--------------
ui/tap_export_pdu.c | 8 +++-
wiretap/file_access.c | 49 ++++++++++--------------
wiretap/merge.c | 23 +++++++++---
wiretap/nettrace_3gpp_32_423.c | 6 ++-
wiretap/wtap.c | 23 ++++++++++++
wiretap/wtap.h | 85 ++++++++++++++++++++++++------------------
11 files changed, 182 insertions(+), 160 deletions(-)