aboutsummaryrefslogtreecommitdiffstats
path: root/wireshark-qt.cpp
AgeCommit message (Collapse)AuthorFilesLines
2017-05-04Add g_get_monotonic_time() to glib-compat and useMartin Mathieson1-0/+4
Change-Id: If41dab19692516270e8b4bcf1a8a954bb8dc3ccc Reviewed-on: https://code.wireshark.org/review/21480 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-04-08Clean up handling of enabled/disabled protocols/heuristic dissectors.Guy Harris1-42/+13
Add a "report a warning message" routine to the "report_err" code in libwsutil, and rename files and routines appropriately, as they don't only handle errors any more. Have a routine read_enabled_and_disabled_protos() that reads all the files that enable or disable protocols or heuristic dissectors, enables and disables them based on the contents of those files, and reports errors itself (as warnings) using the new "report a warning message" routine. Fix that error reporting to report separately on the disabled protocols, enabled protocols, and heuristic dissectors files. Have a routine to set up the enabled and disabled protocols and heuristic dissectors from the command-line arguments, so it's done the same way in all programs. If we try to enable or disable an unknown heuristic dissector via a command-line argument, report an error. Update a bunch of comments. Update the name of disabled_protos_cleanup(), as it cleans up information for disabled *and* enabled protocols and for heuristic dissectors. Support the command-line flags to enable and disable protocols and heuristic dissectors in tfshark. Change-Id: I9b8bd29947cccdf6dc34a0540b5509ef941391df Reviewed-on: https://code.wireshark.org/review/20966 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-03-27Check for return value of WSAStartup on all executables.Michael Mann1-1/+7
Windows vscodeanalysis complains even though the event is probably very unlikely. Change-Id: Iafe158eea5586908209d6bfe1e45540117558673 Reviewed-on: https://code.wireshark.org/review/20727 Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-03-23Qt: Register Qt dialog UAT files during startupStig Bjørlykke1-0/+5
All files which belongs in a configuration profile are registered during startup because they affect copy existing profiles and reset the default profile. UAT files used in Qt dialogs are not loaded during startup because they only get loaded when the dialog is shown. This files must be manually registered. Change-Id: Ib43f5c46b0dbde6994d90512708488cc2bd92f04 Reviewed-on: https://code.wireshark.org/review/20665 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2017-02-18wsutil: remove leaks from filesystem and plugins code.Dario Lombardo1-0/+4
Change-Id: Iac2805c0130bd2ba6cdb3c9dd997050274d58d99 Reviewed-on: https://code.wireshark.org/review/20020 Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-02-14wiretap: add cleanup routine.Dario Lombardo1-0/+1
The cleanup routine has been added to exit section of the applications. Those which required a exit restyle have been patched as well. Change-Id: I3a8787f0718ac7fef00dc58176869c7510fda7b1 Reviewed-on: https://code.wireshark.org/review/19949 Petri-Dish: Dario Lombardo <lomato@gmail.com> Reviewed-by: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Dario Lombardo <lomato@gmail.com>
2017-02-10Clean columns on exit.Dario Lombardo1-0/+1
Change-Id: I950295c35fc67193d9825ebc741da151ad99e077 Reviewed-on: https://code.wireshark.org/review/19941 Petri-Dish: Dario Lombardo <lomato@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-02-03Fix builds without libpcap.Guy Harris1-0/+2
capture_opts_cleanup() doesn't exist if we're building without libpcap, so don't call it if we're building without libpcap. Change-Id: I6c9defea15fac7df5533269c4945b965d9a67c25 Reviewed-on: https://code.wireshark.org/review/19924 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-02-02capture_opts: free memory on exit to avoid leak.Dario Lombardo1-10/+19
This required a restyle of the way the different apps exit. Change-Id: Iedf728488954cc415b620ff0284d2e60f38f87d2 Reviewed-on: https://code.wireshark.org/review/19780 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Dario Lombardo <lomato@gmail.com>
2017-01-05Add g_log entries to measure startup time, protected by #ifdefAndersBroman1-5/+51
Change-Id: Ic32f89dc824a6da838643445a30335a8c73af1ee Reviewed-on: https://code.wireshark.org/review/19540 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-01-05Do RA_DISSECTORS in the Qt UI.Guy Harris1-0/+2
It looks as if a fair bit of work is done under RA_DISSECTORS before we register any individual items, so add it to the splash screen update with the Qt UI - it's used in the GTK+ UI. Update a comment to explicitly indicate what action transactions are being counted (other than the individual-item ones, where we have to call routines that give us a count of items). Change-Id: I3ec5e5fbfdcf523d693bcf1b0f0ffbe0d05d61ae Reviewed-on: https://code.wireshark.org/review/19553 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-01-04Add a startup message for Initializing extcap.AndersBroman1-4/+5
Change-Id: I06262e98bb4a55ee1eacd7a36b938b45eaffaf76 Reviewed-on: https://code.wireshark.org/review/19535 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-12-24Add enabled protocol list for dissectors who are disabled by defaultMichael Mann1-0/+9
We save a list of dissectors that are disabled through the Enabled Protocols dialog. This is because we assume dissectors are enabled by default. For dissectors that are disabled by default, we have no way to keep them enabled through the Enabled Protocols dialog. A dissector that defaults to being disabled has to be reset to enabled each time Wireshark is launched. Add a list similar to the disabled list for enabling dissectors that are disabled by default. This mostly applies to post-dissectors. Change-Id: I31a8d97a9fdbc472fe2a8666384e0f8786bb8e9f Reviewed-on: https://code.wireshark.org/review/19405 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-05Clean up initialization code for programs.Guy Harris1-1/+2
Make the init_progfile_dir() call unconditionally, even if plugins aren't supported, as that doesn't necessarily mean nobody uses the directory containing the executable. Report the error the same way in all programs, and free the error string after we're finished with it. Make the error - and the comment before the code - reflect what init_progfile_dir() is actually doing (the goal is to get the full pathname of the directory *containing* the executable; that's generally done by getting the pathname of the executable and stripping off the name of the executable, but that's won't necessarily always be the case). Also note for TShark that we won't be able to capture traffic, just as we do for Wireshark (if we don't have the pathname of the program file, we don't have a pathname to use to find dumpcap). Have the plugin scanner just fail silently if we weren't able to get the plugin directory path, so we don't have to worry about calling it if init_progfile_dir() fails. Clean up white space while we're at it. Change-Id: I8e580c719aab6fbf74a764bf6629962394fff7c8 Reviewed-on: https://code.wireshark.org/review/19076 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-12-04Have a routine to do all the work of initializing libwiretap.Guy Harris1-2/+1
Have programs that use libwiretap call that routine rather than separately calling some or all of init_open_routines(), wtap_register_plugin_types(), and wtap_opttypes_initialize(). Also don't have routines internal to libwiretap call those. Yes, this means doing some initialization work when it isn't necessary, but scattering on-demand calls throughout the code is a great way to forget to make those calls. Change-Id: I5828e1c5591c9d94fbb3eb0a0e54591e8fc61710 Reviewed-on: https://code.wireshark.org/review/19069 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-12-04Show codec information in About dialogPeter Wu1-0/+2
Show codec libraries in About dialog, this should give the user a clue of what codecs are available. SBC is already supported, Spandsp (for G.722/G.726) is work in progress. Change-Id: Iebc4d9c9fae619a442e06c8afc780a420aa3971b Reviewed-on: https://code.wireshark.org/review/18978 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-12-04codecs: allow it to be used without pluginsPeter Wu1-3/+1
Not all codecs require the plugin infrastructure. For example, G.711U/A is a built-in codec. Allow such functionality to be registered even if plugin support is disabled. Change-Id: I2505cc9955e7953268ec0739531278921f70a771 Reviewed-on: https://code.wireshark.org/review/18977 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-11-10Qt: Handle retranslation events in the main window.Gerald Combs1-1/+1
Update most (but not all) of the main status bar text when the user changes the language setting. Try to distinguish between recent preferences and recent captures more clearly. Change-Id: I5278a503178fe3620a25b185742688f957dc30f4 Ping-Bug: 11307 Reviewed-on: https://code.wireshark.org/review/9575 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-10-30Have routines for parsing options that affect dissection.Guy Harris1-6/+7
Have them handle -d, -t, --disable-protocol, --disable-heuristic, and --enable-heuristic for TShark and both flavors of Wireshark. Change-Id: I612c276b1f9df8a2092202d23ab3d48be7857e85 Reviewed-on: https://code.wireshark.org/review/18583 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-10-20WelcomeUI: Make Open and Capture clickableRoland Knall1-0/+2
Make the texts "Open" and "Capture" clickable, and have them open the FileOpen and CaptureOptions dialogs respectively Change-Id: I2a3efbc4cdf160aa0b4efc6496d09228affbff46 Reviewed-on: https://code.wireshark.org/review/18303 Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl> Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-10-17Qt: Read our dynamic recent entries a bit earlier.Gerald Combs1-9/+10
Call recent_read_dynamic a bit earlier in the startup process. Note that it determines when we fill in the recent files list, so the earlier we call it the better. Change-Id: Iad37d3aa2222873259d6c96ba79672236c8e4cd5 Reviewed-on: https://code.wireshark.org/review/18235 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-09-16Qt: Argument vector fixups.Gerald Combs1-8/+8
In wireshark-qt.cpp we have two "argv" variables, one that we pass to QCoreApplication (which it then corrupts irreversibly on Windows if you pass it multibyte characters), and one that we convert to UTF-8 and use normally. Name the throwaway argument vector "qt_argv". Name ours "argv", which is the traditional and less error-prone name. Bug: 12900 Change-Id: Idd80b9f779f36ffe977465afd623d320212f92b1 Reviewed-on: https://code.wireshark.org/review/17723 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-09-12fix some compilation issues without extcap.Dario Lombardo1-0/+2
Change-Id: I18c855e13281013a6277c1f38eeac92e74d52b34 Reviewed-on: https://code.wireshark.org/review/17665 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-09-11qt: fix minor memory leaks on exitPeter Wu1-0/+2
Change-Id: I4856b7ce7eec15abe1278e9ba8314be61845347a Reviewed-on: https://code.wireshark.org/review/17638 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-09-11extcap: fix use-after-free for preferencesPeter Wu1-4/+2
In commit v2.3.0rc0-117-g485bc45 (backported to v2.2.0rc0-44-g66721ca), extcap_prefs_dynamic_vals and extcap_cleanup were added in an attempt to address dangling pointers. Unfortunately it is not sufficient: - A pointer to the preference value is stored in extcap_arg and passed to the prefs API, but this extcap_arg structure can become invalid which result in use-after-free whenever the preference is accessed. - On exit, a use-after-free occurs in prefs_cleanup when the preference value is being checked. As the preference subsystem actually manages the memory for the string value and consumers should only provide a pointer where the value can be stored, convert the char* field in extcap to char**. This has as additional benefit that values are not limited to 256 bytes anymore. extcap_cleanup is moved after epan_cleanup to ensure that prefs_cleanup does not operate on dangling pointers. Crash is reproducible under ASAN with: tshark -i randpkt Ping-Bug: 12183 Change-Id: Ibf1ba1102a5633aa085dc278a12ffc05a4f4a34b Reviewed-on: https://code.wireshark.org/review/17631 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Roland Knall <rknall@gmail.com>
2016-09-05Have scan_plugins() take an argument specify what to do on load failures.Guy Harris1-1/+1
That's a less gross hack to suppress load failures due to not having libwiretap than providing a no-op failure-message routine, as it at least allows other code using a failure-message routine, such as cmdarg_err() and routines that call it, to be used. We really should put libwiretap and libwireshark plugins into separate subdirectories of the plugin directories, and avoid even looking at libwireshark plugins in programs that don't use libwireshark. Change-Id: I0a6ec01ecb4e718ed36233cfaf638a317f839a73 Reviewed-on: https://code.wireshark.org/review/17506 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-08-01Fix compilation without extcap.Dario Lombardo1-0/+1
Change-Id: I627dd6c514066ba67cd501925ff95e9cf819c0e9 Reviewed-on: https://code.wireshark.org/review/16828 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Roland Knall <rknall@gmail.com>
2016-07-29extcap: Restore functionality for optionsRoland Knall1-0/+4
Allow stored options to be restored to their default values. This adds a global cleanup method for extcap and globally defined preference values, which fixes the parameter problem with windows Change-Id: I48e0cf846ef81f4732d652c6a2ad0020db5df08e Reviewed-on: https://code.wireshark.org/review/13741 Petri-Dish: Roland Knall <rknall@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Roland Knall <rknall@gmail.com>
2016-07-01Qt+Gtk: Fix the -t command line flag.Gerald Combs1-1/+0
Add the time format to commandline_param_info_t and apply it when we've finished application initialization. Bug: 12489 Change-Id: Ice626198a610567e945a8e53c0c1093797e8208e Reviewed-on: https://code.wireshark.org/review/16232 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-06-28Have commandline_other_options() directly fill in the global structure.Guy Harris1-1/+1
Other code looks at the global structure, so there won't be other structures; just fill in the global structure directly. Change-Id: I4dc87b79168c5a7c9ab1f085aa2d78cc6d2c9019 Reviewed-on: https://code.wireshark.org/review/16184 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-28Make quit_after_cap an item in commandline_param_info_t.Guy Harris1-28/+27
And make the commandline_info structure global, so all the places that look at quit_after_cap can get at it. Change-Id: I006329cf8842c655cca36f024570855d1b16e107 Reviewed-on: https://code.wireshark.org/review/16182 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-27qt: fix linking error with global_capture_optsPeter Wu1-4/+0
global_capture_opts is already defined by ui/commandline.c which is also linked with wireshark-qt.cpp. Remove the duplicate definition to avoid a build failure with the gold linker. Fixes regression from v2.1.1rc0-192-g9b5b444. Change-Id: I4484e2769bf270dee1ec0378fd9c925e01eaf390 Reviewed-on: https://code.wireshark.org/review/16175 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-06-26Add an RA_INTERFACES register action.Gerald Combs1-0/+2
Add RA_INTERFACES between RA_PREFERENCES and RA_CONFIGURATION. Wireshark was spending a suspiciously long time loading module preferences here. (Now we just need to find out why that section of the code is slow.) Change-Id: Iecbe55e8e10c8844bcb151a13e383cb13a3f6eb1 Reviewed-on: https://code.wireshark.org/review/16133 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-25Minor UI locale updates.Gerald Combs1-6/+6
Qt: Call setlocale before commandline_early_options so that we get proper "-v" output, similar to the GTK+ UI. GTK+: Call setlocale once at startup. Bug: 11960 Change-Id: I3c3a196b9d94fc768e1085200891bc8d67e21a08 Reviewed-on: https://code.wireshark.org/review/16132 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>
2016-06-23Qt: Support the -j, -J, and -l command line flagsGerald Combs1-0/+16
Add support for -j, -J, and -l. Mark the -m flag deprecated. Bug: 12546 Change-Id: Ic44b3997840018e5d571aa1813a1646bce11d4a6 Reviewed-on: https://code.wireshark.org/review/16083 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-06-21pcap: Add support to "new" Npcap native mode without setting PATHYang Luo1-0/+1
Npcap decided not to add "C:\Windows\System32\Npcap" to system PATH in the installation any more (starting from Npcap 0.07 r14). So this patch needs to be applied, otherwise Wireshark will not find Packet.dll (the error message will only say wpcap.dll is missing, but actually is Packet.dll missing). Change-Id: Ifd8b6e6d8ecf9866cd37c3368b604de210ff8c7b Reviewed-on: https://code.wireshark.org/review/15959 Reviewed-by: Yang Luo <hsluoyz@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-06-20Pull the options structure initialization into commandline_other_options().Guy Harris1-15/+0
Change-Id: I931cde27a81566dfa0ce6e5c9307bfc1a4d5fe54 Reviewed-on: https://code.wireshark.org/review/16033 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Move some option checking to common code.Guy Harris1-48/+0
Change-Id: Icff9dacd73ea933c59ed664db05098dd8cb3dbf5 Reviewed-on: https://code.wireshark.org/review/16029 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Pass the info strings directly to commandline_early_options().Guy Harris1-8/+6
Just pass them directly as arguments, don't stuff them into a structure. Change-Id: Iac84226f54898bc953011bca64795e9049762905 Reviewed-on: https://code.wireshark.org/review/16022 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Handle capture options in pcap-less Wireshark in the commandline_ routines.Guy Harris1-6/+0
Get rid of the capture_option_specified and arg_error members of the commandline_capture_param_info_t and commandline_param_info_t structures, and have them be local variables in commandline_early_options() and commandline_other_options(). Have commandline_early_options() print the "sorry, Wireshark wasn't built with pcap" and exit if -D was specified but Wireshark wasn't built with pcap. Change-Id: I0efcdea89d9585af8f3c0a28aee060f33d3ec5fd Reviewed-on: https://code.wireshark.org/review/16021 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Those aren't capture options, they're the options we must process early.Guy Harris1-1/+1
The only one of those options that has anything to do with packet capture is -i, and all we do there is check for an argument of "-"; the rest are either 1) options that affect your preference settings (-C to select the profile, -P to set the personal file directory path); 2) options that just print something to the standard output or error and exit, before firing up the GUI; 3) extension command line options (-X). Change-Id: Iba9b8b14fe468e2ca9d4c67e1a9b8103603678d9 Reviewed-on: https://code.wireshark.org/review/16019 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Get rid of an unused variable; set a structure member.Guy Harris1-1/+0
There's no need for the capture_option_specified variable, but we *do* need to initialize the capture_option_specified member of *param_info before parsing the flags. Change-Id: I89d0b8c338c2784742b21ba4e854f702ce491849 Reviewed-on: https://code.wireshark.org/review/16017 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Revert "tap: change glib functions to wmem."Pascal Quantin1-10/+10
This reverts commit 2e9f3c5d366eaa7139fc877b5301392166b3f985. It breaks the registration of codec, dissector and libwiretap plugins. Change-Id: I4ef91dd192f765adf87ea9fe9f3693e25dbd24de Reviewed-on: https://code.wireshark.org/review/16012 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-06-19Put #ifdef/#endif around a variable used only on Windows.Guy Harris1-1/+4
Change-Id: Ia6fed6db03cb88433469e758693fcc72c4bd9071 Reviewed-on: https://code.wireshark.org/review/16009 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-19Refactor command-line handling of GUI options.Michael Mann1-566/+58
Both GTK and Qt both use the same command-line options, so refactor the parsing and (possibly) applying of those arguments to a single location. Ping-Bug: 12546 Change-Id: Ib31e576c509c5d3d21c33d3247640d9f9c68661b Reviewed-on: https://code.wireshark.org/review/16006 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-17tap: change glib functions to wmem.Dario Lombardo1-10/+10
Change-Id: I878ae6b121a669f9b7f4e1e57bc079f0cb44c0bf Reviewed-on: https://code.wireshark.org/review/15270 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Evan Huus <eapache@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-13Qt: add some cleanup function calls missing when leaving applicationPascal Quantin1-2/+18
Change-Id: I8f22d321e84daa36d4a40856b61d0844d3489cc2 Reviewed-on: https://code.wireshark.org/review/15374 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-05-11Qt: fix loading of profile by command linePascal Quantin1-11/+13
recent_read_static() must be called before processing the -C option as it will select the last profile used. While we are at it, add a missing profile_store_persconffiles(FALSE) call to match what is done in GTK based UI Bug: 12425 Change-Id: I9cfdca3ed25f0ed97535178973e3f0427b9ad2b1 Reviewed-on: https://code.wireshark.org/review/15371 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-04-21Link version code statically againJoão Valverde1-1/+1
This allows keeping the code-sharing with the static linking. This "fixes" a hypothetical ABI mismatch with wsutil and avoids pulling more external dependencies to wsutil than strictly necessary. A nice side-effect is that libwsutil no longer depends on version.h. Follow up to f95976eefcbeb5d24df383c29d29ef888b503945. Change-Id: I8f0d6a557ab3f7ce6f0e2c269124c89f29d6ad23 Reviewed-on: https://code.wireshark.org/review/15002 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>
2016-04-04Include ws_diag_control.h in config.hJoão Valverde1-1/+0
Change-Id: Ia394071710ecda3b0e6686a51fbca45a8ff20317 Reviewed-on: https://code.wireshark.org/review/14749 Petri-Dish: João Valverde <j@v6e.pt> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>