diff options
author | Guy Harris <guy@alum.mit.edu> | 2018-11-12 15:43:10 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2018-11-13 03:37:29 +0000 |
commit | 3faa45d4ec9214fbe4b15c3b6d9bc875f8fb780c (patch) | |
tree | 98cc11031a83c66e6bbbd22ebe6c3581ca9392be /ui | |
parent | f070ad2c1eb2813be5d7e27b1e1bb7b844d8467e (diff) |
Don't have _ng versions of the dumper open routines.
Have the routines always take a parameters pointer; pass either null or
a pointer to an initialized-to-nothing structure in cases where we were
calling the non-_ng versions.
Change-Id: I23b779d87f3fbd29306ebe1df568852be113d3b2
Reviewed-on: https://code.wireshark.org/review/30590
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'ui')
-rw-r--r-- | ui/qt/import_text_dialog.cpp | 4 | ||||
-rw-r--r-- | ui/tap_export_pdu.c | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/ui/qt/import_text_dialog.cpp b/ui/qt/import_text_dialog.cpp index af5f584705..c1ead47a88 100644 --- a/ui/qt/import_text_dialog.cpp +++ b/ui/qt/import_text_dialog.cpp @@ -118,10 +118,12 @@ QString &ImportTextDialog::capfileName() { void ImportTextDialog::convertTextFile() { char *tmpname; int err; + wtapng_dump_params params; capfile_name_.clear(); + wtap_dump_params_init(¶ms, NULL); /* Use a random name for the temporary import buffer */ - import_info_.wdh = wtap_dump_open_tempfile(&tmpname, "import", WTAP_FILE_TYPE_SUBTYPE_PCAP, import_info_.encapsulation, import_info_.max_frame_length, FALSE, &err); + import_info_.wdh = wtap_dump_open_tempfile(&tmpname, "import", WTAP_FILE_TYPE_SUBTYPE_PCAP, import_info_.encapsulation, import_info_.max_frame_length, FALSE, ¶ms, &err); capfile_name_.append(tmpname ? tmpname : "temporary file"); qDebug() << capfile_name_ << ":" << import_info_.wdh << import_info_.encapsulation << import_info_.max_frame_length; if (import_info_.wdh == NULL) { diff --git a/ui/tap_export_pdu.c b/ui/tap_export_pdu.c index a6eea7d924..5b3788e615 100644 --- a/ui/tap_export_pdu.c +++ b/ui/tap_export_pdu.c @@ -145,11 +145,11 @@ exp_pdu_open(exp_pdu_t *exp_pdu_tap_data, int fd, char *comment) .idb_inf = exp_pdu_tap_data->idb_inf, }; if (fd == 1) { - exp_pdu_tap_data->wdh = wtap_dump_open_stdout_ng(WTAP_FILE_TYPE_SUBTYPE_PCAPNG, + exp_pdu_tap_data->wdh = wtap_dump_open_stdout(WTAP_FILE_TYPE_SUBTYPE_PCAPNG, WTAP_ENCAP_WIRESHARK_UPPER_PDU, WTAP_MAX_PACKET_SIZE_STANDARD, FALSE, &ng_params, &err); } else { - exp_pdu_tap_data->wdh = wtap_dump_fdopen_ng(fd, WTAP_FILE_TYPE_SUBTYPE_PCAPNG, + exp_pdu_tap_data->wdh = wtap_dump_fdopen(fd, WTAP_FILE_TYPE_SUBTYPE_PCAPNG, WTAP_ENCAP_WIRESHARK_UPPER_PDU, WTAP_MAX_PACKET_SIZE_STANDARD, FALSE, &ng_params, &err); } |