Wireshark mailing list archives
Re: GUIManger in menus.c
From: Jeff Morriss <jeff.morriss.ws () gmail com>
Date: Fri, 01 Oct 2010 18:39:08 -0400
Anders Broman wrote:
Jeff Morriss skrev 2010-10-01 23:05:Anders Broman wrote:Jeff Morriss skrev 2010-10-01 16:43:Anders Broman wrote:-----Original Message----- From: wireshark-dev-bounces () wireshark org [mailto:wireshark-dev-bounces () wireshark org] On Behalf Of Guy Harris Sent: den 1 oktober 2010 02:30 To: Developer support list for Wireshark Subject: Re: [Wireshark-dev] GUIManger in menus.c On Sep 30, 2010, at 3:29 PM, Jeff Morriss wrote:Anders Broman wrote:Hi, When using GUIManager for the main menu bar, it blows up loading a file. Could some one take a look and help me figure out what's wrong? The recent file stuff is also broken - probably related.It's bailing out here: ERROR:column-utils.c:1175:col_set_cls_time: code should not be reached That means timestamp_set_type() has not been called. When we're not using GUIManager, that function is called (during startup) in timestamp_format_cb(). That function is not called during startup when using GUIManager... Hmmm, actually it's not being called at all.It's called in: change_configuration_profile() (after reading the "recent" file, it's set to the value from that file) main(), if "-t" is specified; reftime_answered_cb() (if you answer "yes" to "Do you want to switch to "Seconds Since Beginning of Capture" now?") timestamp_format_cb() (when you explicitly set it through the GUI) change_configuration_profile() is called only in profile_select() and select_profile_cb(), when you choose a profile. The reason why it doesn't start out as TS_RELATIVE in Wireshark is, to quote the comment: so that "recent" in gtk/menu.c can detect this and distinguish it from a command line value That refers to menu_recent_read_finished(), which sets recent.gui_time_format to the current time stamp value if>it's not TS_NOT_SET, i.e., if it was set on the command line, that setting overrides whatever is in the recent file. Is there some reason not to read the recent file *before* parsing the command-line arguments, so that we can just have the time stamp format initialized to TS_RELATIVE, override it from the recent file, and then possibly>override *that* from the command line?I have checked in some changes to menus.c, - earlier read of prefs is still a good idea - It still crashes, but I don't get a decent indication of where - help?Try 34310. It looks like you fixed the timestamp issue--can load a capture file now. :-)It should have been the double slashes "//Menubar.." that caused that. Unfortunately I still get a crash on Windows...The double slashes didn't change anything for me; I just took it out since it looked like a typo. Without the if(widget) check, it always crashes for me. With the check it works fine. Hmmm...The path was wrong fixed in revision 34318. Still no joy though :-(
OK, now the widget seems to be there. Still no crash though. What are you doing when it crashes? I can do wireshark -r file or start it and do File->Open to open a file and get no crashes. ___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- Re: GUIManger in menus.c Anders Broman (Oct 01)
- Re: GUIManger in menus.c Jeff Morriss (Oct 01)
- Re: GUIManger in menus.c Anders Broman (Oct 01)
- Re: GUIManger in menus.c Jeff Morriss (Oct 01)
- Re: GUIManger in menus.c Anders Broman (Oct 01)
- Re: GUIManger in menus.c Jeff Morriss (Oct 01)
- Re: GUIManger in menus.c Anders Broman (Oct 01)
- Re: GUIManger in menus.c Anders Broman (Oct 01)
- Re: GUIManger in menus.c Jeff Morriss (Oct 01)