Commit Graph

508 Commits

Author SHA1 Message Date
Anders Broman de19187a4f From Evan Huus: Reset the comment tree when the filter changes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7317
svn path=/trunk/; revision=43038
2012-06-03 17:52:05 +00:00
Guy Harris 19dfeda6d6 Note in a comment that we should perhaps handle safe-saving on top of a
symlink.

svn path=/trunk/; revision=43037
2012-06-03 17:35:34 +00:00
Guy Harris cd90f2b6f5 gedit, at least, says
The file "xxx" is read-only.

if you try to save over a file that has no read permission bits.

svn path=/trunk/; revision=43036
2012-06-03 17:25:08 +00:00
Anders Broman dbc4b09004 From Evan Huus Convert a bunch more GTK-2 calls to their cross-version ws_ equivalent
svn path=/trunk/; revision=43009
2012-06-02 23:53:04 +00:00
Guy Harris 68a4971594 If the user tries to save a capture file atop a file that has all its
write bits turned off or, on 4.4-Lite-based systems, has its "user
immutable" bit turned on, ask them if they really want to overwrite the
file (as those are both used to say "this file is precious, don't let me
easily accidentally trash it") and, if the "user immutable" bit is set,
turn it off first so that the move in the "safe save" won't fail.

svn path=/trunk/; revision=43006
2012-06-02 18:53:13 +00:00
Guy Harris 2e4f30d0f9 The only reason we need to do locale conversions is that path names as
returned by the file selection dialog are in the locale's character
encoding.  Just convert those, and use the formatting capabilities of
the GTK+ message dialog rather than formattting the message to a string
and translating it in its entirety.

Use g_filename_display_basename() to do the locale conversion while
we're at it.

svn path=/trunk/; revision=43005
2012-06-02 18:13:12 +00:00
Guy Harris 49216b1091 Clean up indentation.
svn path=/trunk/; revision=43004
2012-06-02 17:05:12 +00:00
Anders Broman b647402c60 From Evan Huus Memory leak in voip_calls.c https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7320
svn path=/trunk/; revision=42997
2012-06-02 13:28:42 +00:00
Jeff Morriss d4fdd6ad52 Only propose decoding PPID 0 if that PPID is in the currently-selected frame.
(I used PPID 0xffffffff as an end-of-list marker so that PPID can no longer
be used in this dialog; if someone starts using that PPID then we'll have
to put a count of PPIDs in pinfo.)

svn path=/trunk/; revision=42991
2012-06-01 21:18:59 +00:00
Anders Broman 86c69b01e7 From Alexander Koeppe.
Patch that creates the filter according to the protocol tree selected.
Fixes
IPv6 filters built from "Protocol Hierarchy Statistics" dialog not specific
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7250

svn path=/trunk/; revision=42960
2012-06-01 07:02:04 +00:00
Jakub Zawadzki c725ee11a6 Fix part of bug #4030
GeoIP strings from r39299 are encoded in UTF-8 so don't use format_text.

svn path=/trunk/; revision=42911
2012-05-30 06:44:37 +00:00
Anders Broman fa11167ea1 From Evan Huus:
Misc resource leaks.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7296

svn path=/trunk/; revision=42892
2012-05-29 07:27:35 +00:00
Chris Maynard 3e52049ff5 Fix Coverity CID's 702388 and 702422: OVERFLOW_BEFORE_WIDEN.
svn path=/trunk/; revision=42886
2012-05-28 18:37:10 +00:00
Guy Harris 53375198ec Don't use pcap LINKTYPE_ values in the iface_options structure, use
Wiretap encapsulation values; rename the field in question encap_type to
emphasize that.  (Code that looks at that field already assumes it's a
Wiretap encapsulation value.)

For live captures, map the LINKTYPE_ value to a Wiretap encapsulation
value.

wtap_encap_string() never returns NULL, so don't check for a null return
value.

svn path=/trunk/; revision=42871
2012-05-28 00:31:27 +00:00
Guy Harris e6ec5d8f50 From Evan Huus in bug 7295:
cppcheck realized that if_info is known not to be null in that code
path, and therefore that checking whether it's null in that code path is
unnecessary.  Remove it.

svn path=/trunk/; revision=42867
2012-05-27 20:47:57 +00:00
Guy Harris d7279caa93 From Evan Huus from bug 7295:
Fix an ancient copy-and-pasteo of mine ("me" here meaning Guy Harris,
not Evan Huus) - remove an unused data structure (used in the code I
copied and pasted to make this code, not used here).

svn path=/trunk/; revision=42866
2012-05-27 20:45:16 +00:00
Guy Harris 6014035703 Use GTK+'s GtkMessageDialog for the questions we ask in the process of
saving files, and run it modal (which we're already doing with the
GtkFileChooserDialog); this means less callback-based state machine
stuff, simplifying the code paths a bit.

If we're saving a file before closing it, don't bother reloading it
after saving it.

svn path=/trunk/; revision=42855
2012-05-25 21:25:55 +00:00
Guy Harris cc4f738fc0 Well, "ui/gtk/capture_file_dlg.h" is needed on Win32.
svn path=/trunk/; revision=42851
2012-05-25 09:58:42 +00:00
Guy Harris c48b78bbee ui/gtk/capture_file_dlg.h doesn't need to be included in these files.
svn path=/trunk/; revision=42850
2012-05-25 09:26:45 +00:00
Chris Maynard ada62f22a8 If either create_persconffile_dir() or ws_fopen() fail, then bail out. This avoids potentially dereferencing "daf" if it's NULL and fixes Coverity CID 281275.
svn path=/trunk/; revision=42841
2012-05-25 00:43:32 +00:00
Jeff Morriss 135ebc4148 Don't include a Clear button in the packet- and capture-file-comment dialogs:
the user can just Ctrl-A + backspace if they want to do that.

svn path=/trunk/; revision=42836
2012-05-24 21:38:22 +00:00
Jeff Morriss 373e0925f3 Enable word wrapping for capture-file comments.
svn path=/trunk/; revision=42835
2012-05-24 21:35:41 +00:00
Jeff Morriss 9ea08d6b12 Get rid of the button row for the capture-file comments. Instead, turn the
whole summary dialog into an editor-like dialog with an OK and Cancel buttons
(OK sets the new capture file comment, Cancel doesn't).

In order to keep the dialog the same regardless of the file type (and avoid
having a Cancel and OK button when there's no text field to edit), allow
users to create or edit capture-file comments even if the file type is not
PCAPNG (they can add a comment via the add/edit comment UI anyway).

Don't include a Clear button: the user can just Ctrl-A + backspace if they
want to do that.

Don't set the comment text to "[None]" if there's no comment, just leave it
blank.

Don't allow the user to create more than 1 Summary dialog at a time.

svn path=/trunk/; revision=42834
2012-05-24 21:33:25 +00:00
Guy Harris 0d6e9145be Word-wrap comments in the display.
svn path=/trunk/; revision=42833
2012-05-24 19:18:31 +00:00
Jeff Morriss a4bbd97979 Use cf_update_capture_comment() to save the capture comment (instead of
summary_update_comment() which is no longer necessary).
cf_update_capture_comment() has the advantage that it doesn't mark the file
as unsaved unless the comment actually changed.

svn path=/trunk/; revision=42832
2012-05-24 18:59:39 +00:00
Jeff Morriss 474281be2a Free the new comment after calling gtk_text_buffer_set_text().
svn path=/trunk/; revision=42831
2012-05-24 18:55:38 +00:00
Jeff Morriss b32c6c0658 menu_dissector_filter(): free the action_name when we're done with it.
capture_cb(): if we strrchr() didn't find a seperator, don't use
g_strdup_printf() to format the action_name (since that would have to be
freed), just set it to the action_name.

svn path=/trunk/; revision=42829
2012-05-24 18:26:52 +00:00
Jeff Morriss c1e2dd357d Free the comment after calling gtk_text_buffer_set_text().
svn path=/trunk/; revision=42828
2012-05-24 18:11:55 +00:00
Jeff Morriss 56199c1328 Also allow the user to edit the capture-file comment if there is one (not
only if the capture file format is PCAPNG).  This can happen if the user
does not have a PCAPNG file but has added a capture-file comment via the
add/edit capture file comment UI.

Replace some tabs with spaces and wrap a few long lines.

svn path=/trunk/; revision=42827
2012-05-24 15:16:18 +00:00
Guy Harris facd4aca9d Now that cf_save_packets() can avoid doing a "fast path" save if the
source isn't compressed and the target is (or vice versa), enable the
"compressed" checkbox in the Save As and Export Specified Packets
dialog.  Fix it to clear the checkbox if the selected file format
doesn't support gzipping.

svn path=/trunk/; revision=42822
2012-05-24 07:51:39 +00:00
Guy Harris cf6d9841e3 Keep track, in Wiretap, of whether the file is compressed, and provide
an API to fetch that.

When doing "Save" on a compressed file, write it out compressed.

In the Statistics -> Summary dialog and in capinfos, report whether the
file is gzip-compressed.

svn path=/trunk/; revision=42818
2012-05-24 05:05:29 +00:00
Guy Harris b655197a9d In the "Save As" and "Export Specified Packets" code path, do a "safe
save" if the destination file exists.

Don't forbid overwriting an existing file in either of those cases (we
still forbid overwriting the current capture file) - the GUI asks the
user whether they want to do the overwrite, and allows them to cancel
out of it - and don't remove the file before writing to it (doing so
makes the save *un*safe).

Attempt to do a save of an unedited temporary file by just moving the
file on Windows as well as on UN*X - ws_rename() will remove the target
if necessary on Windows (and won't do it as a separate operation before
attempting the rename), so it behaves like ws_rename() on UN*X (which is
just a wrapper around rename()).

svn path=/trunk/; revision=42816
2012-05-24 02:16:53 +00:00
Anders Broman 0832853fa8 From Robert Bullen:
The Wireshark and tshark TCP conversations stats tables aggregate reused connections into a single line item

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7248

svn path=/trunk/; revision=42806
2012-05-23 06:36:47 +00:00
Guy Harris ef163bb569 Separate callback to control the file type combo box in the "Export
Specified Packets" dialog.

svn path=/trunk/; revision=42795
2012-05-22 22:57:37 +00:00
Guy Harris 07835ce129 Do the "Save As always saves the entire capture, Export Specified
Packets saves specified packets" stuff for Windows.

svn path=/trunk/; revision=42794
2012-05-22 22:39:30 +00:00
Guy Harris c2bb7956c2 "Save As" always saves everything and, when the save is done, makes the
new file the current file, as is the case in most if not all other GUI
applications.

A new "Export Specified Packets" menu option allows you to specify which
packets to write out, with the default being the displayed packets (and
those on which the displayed packets depend for, e.g.  reassembly), and
never makes the resulting file the current file.

The two operations are conceptually distinct.  Lumping them into one
menu item, with the default for "Save As" being "displayed packets only"
and thus making it behave like the latter operation, was causing some
confusion; see, for example, bug 6640.

Make the dialog popped up if you try to "Save As" or "Export Specified
Packets" on top of an existing file ask the "do you want to do this?"
question in the main part of the message, and note in the secondary text
that doing that will overwrite what's in the file; that matches what
TextEdit on OS X and the GNOME text editor say.

svn path=/trunk/; revision=42792
2012-05-22 22:17:57 +00:00
Guy Harris 1d41075db1 Replace the File -> Export menu with separate:
File -> Export Packet Dissections

	    (for the "print to file", "export as CSV", "export as C array",
	    "export as PSML", and "export as PDML" items)

	File-> Export Selected Packet Bytes

	File -> Export SSL Session Keys

	File -> Export Objects

	    (for exporting objects transferred over HTTP, DICOM, or SMB)

menu items.

The operations under Export really weren't that related - about all they
had in common was that they wrote to a file stuff other than packets
in a capture file format; the operations in the groups *under* Export
were related, so the groups are now menu items of their own.

This way, the File menu more immediately indicates what options of that
sort are available.

It also means that the Export Packet Dissections item might make it
clearer that what you get from that is *NOT* something that can just be
read back into Wireshark, as at least one user who asked "how do I get
my capture back from this?" on ask.wireshark.com thought.  If that
doesn't suffice, perhaps renaming it to "Export Dissected Packets" would
help; if *that* doesn't suffice, perhaps Kevin Cullimore's suggestion
that it say "Report" rather than "Export" will do the trick:

	From: Kevin Cullimore <kcullimo@runbox.com>
	Subject: [Wireshark-users] Re: Should the "export as text" item be in an "Export Human-readable..." item in the File menu?
	Date: May 19, 2012 8:31:23 PM PDT
	To: wireshark-users <wireshark-users@wireshark.org>

	Would classifying the asymmetric export (ones that lack a
	corresponding "import" action) formats as "reports" help clear
	up the original ambiguity/misunderstanding? It seems that most
	of the gui-based network tools I'm forced to periodically
	interact with rely upon that term with at least some success.

(Or perhaps some other verb would be right in some cases, e.g. "Save SSL
Session Keys".)

This also sets a pattern for another upcoming change - splitting "Save
As" into "Save As", which always saves every packet and makes the new
file the current file, and "{Verb} Specified Packets", which lets you
specify which packets to save and does *not* make the new file the
current file.  That'd simplify the code a bit, and might clear up the
new only-in-the-trunk issue in bug 6640 - having "Save As" default to
saving displayed packets currently means that it acts more like the
latter of those functions.

svn path=/trunk/; revision=42778
2012-05-22 11:44:55 +00:00
Guy Harris ae7d57d5fa We're an editor now, as we let you add, delete, and edit frame comments,
so "Save" should, for non-temporary files, mean "save the current state
of the capture file on top of the existing file" without prompting for a
file name.

That means we have to do a "safe save" - i.e, write the capture out to a
new file and, if that succeeds, rename the new file on top of the old
file - as the actual packet data to write out is in the file we're
overwriting, not in memory.  (We'd want to do that anyway, of
course....)

Update some comments.

Clean up indentation slightly, and get rid of an unnecessary variable
(in all the cases where we use it, we assign it the same value, and that
value isn't modified out from under us before we use it).

Note that after a "Save", or a "Save As" that writes out all captured
packets, we shouldn't have to close the current file and open the new
file and reread it - we should be able to open the new file and update
the frame offsets in the frame_data structures.

Note that we need to do some a better job of reporting rename failures.

svn path=/trunk/; revision=42777
2012-05-22 10:36:40 +00:00
Guy Harris 90c43120ca The GUI's state machine requires that, when reloading a capture after a
save, we post capture file callback events similar to the ones posted
when reading a capture - otherwise, the reload will leave the welcome
screen up.

Rename cf_cb_file_save_reload_finished to cf_cb_file_reload_finished,
add a cf_cb_file_reload_started callback, have them work similarly to
read_finished and read_started except that the reload uses "Reloading"
in the progress bar and status bar.

Clean up some indentation while we're at it.

svn path=/trunk/; revision=42764
2012-05-22 03:52:12 +00:00
Guy Harris 4a9b825c49 Change the "user_saved" member of a capture_file structure to
"unsaved_changes", and have it be TRUE iff changes have been made to the
file since it was read - *not* if it's a temporary file from a live
capture.

Check the "is_tempfile" member, and the "unsaved_changes" member, when
appropriate.

Just have a set_toolbar_for_capture_file() routine that updates the
"save", "close", and "reload" toolbar as appropriate, given a
capture_file structure - absorb the function of
set_toolbar_for_unsaved_capture_file() into it.

svn path=/trunk/; revision=42721
2012-05-20 08:56:06 +00:00
Bill Meier a297af9d64 Add an 'if' test to prevent a potential null pointer dereference
identified by clang scan-build.


svn path=/trunk/; revision=42719
2012-05-19 17:21:32 +00:00
Bill Meier 576fcd2a47 Rework 'ct_nb_switch_page_cb()' slightly to prevent a scan-build "null pointer de-reference" message;
(In practice, the "null pointer de-reference" would not actually occur ?).

svn path=/trunk/; revision=42718
2012-05-19 16:55:22 +00:00
Jakub Zawadzki e8c69cef7e Free memory when create_tempfile() failed.
svn path=/trunk/; revision=42654
2012-05-16 09:07:19 +00:00
Gerald Combs 09487194e4 Check the return value of create_tempfile. Fixes CIDs 280527 and 280528.
svn path=/trunk/; revision=42645
2012-05-16 00:27:26 +00:00
Gerald Combs 9d9aa0f241 Don't leak an open file handle (CID 702423).
svn path=/trunk/; revision=42642
2012-05-15 22:25:35 +00:00
pascal 78d983a963 From Akos Lukovics:
Fix div-by-zero error in the moving average filter of IO graph
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6236

svn path=/trunk/; revision=42598
2012-05-12 15:19:25 +00:00
Jakub Zawadzki 35745a33cd Fix bug #7251
We're already checking in gtk if end highlight offsets don't exceed len.
Do the same for start offset.

I wonder if it this checks should be also done when adding items to tree...

svn path=/trunk/; revision=42596
2012-05-12 07:57:51 +00:00
Guy Harris f1b11f62f8 proto_registrar_get_ftype() returns an FT_ value; make its return type
"enum ftenum" to reflect that, and fix the "switch doesn't handle XXX"
warnings that provokes.

svn path=/trunk/; revision=42579
2012-05-11 17:29:56 +00:00
Jakub Zawadzki 709d04976c Avoid calling tvb_get_ptr() on 0-length TVBs.
It seems to be better fix than r42420

svn path=/trunk/; revision=42460
2012-05-07 10:51:14 +00:00
Bill Meier a703450659 AFAICT '#include sys/types.h' is not needed for these files.
svn path=/trunk/; revision=42443
2012-05-05 20:51:14 +00:00
Bill Meier f672e4822a Cosmetic change....
svn path=/trunk/; revision=42440
2012-05-05 16:02:36 +00:00
Jeff Morriss 7afb363eab Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6892 :
Sort the recent filters list by "most recently used" (that is, put the most
recently used filter at the head of the list).

svn path=/trunk/; revision=42439
2012-05-05 15:09:19 +00:00
Jeff Morriss 24f5265620 Clean up white space and indentation; remove tabs.
svn path=/trunk/; revision=42438
2012-05-05 14:37:19 +00:00
Jakub Zawadzki fd38b34c2c Fix opening packet window when frame has got cap_len = 0 (i.e. last frame from mime_file reader)
Workaround, if someone has better idea how to fix it, please do.

svn path=/trunk/; revision=42420
2012-05-04 10:28:16 +00:00
Jakub Zawadzki 8bf8070340 Add proto_hier_tree_model.c to CMakeLists
svn path=/trunk/; revision=42419
2012-05-04 08:17:46 +00:00
Jakub Zawadzki 82b077278c cleanup proto_hier_tree_model a little.
svn path=/trunk/; revision=42415
2012-05-04 06:08:22 +00:00
Jakub Zawadzki fdaa9aa3ac Fix memleak of GtkTextBuffer
svn path=/trunk/; revision=42414
2012-05-04 05:56:38 +00:00
Anders Broman 0cea399fda From Jakub Zawadzki: Use custom model in Filter Expression dialog.
svn path=/trunk/; revision=42411
2012-05-04 04:44:23 +00:00
Anders Broman 77074a5a37 From Evan Huus: - Make sure that unsupported link-layer types *always* have a dlt of -1 in the `device.links` list so that we can tell if they're unsupported. - When building the combo-box of link-layer types, make the unsupported ones insensitive (disabled), and be sure to default to a supported one if we have one. - Compiling a capture filter requires a supported link-layer type, so disable the 'Compile BPF' button if there are none. - It is not always a programming error to have no active pointer in the combo-box, as this can happen when all the available entries are unsupported (and thus disabled). Don't abort with g_assert_not_reached() when this happens. - Unlock the `pcap_compile_mtx` mutex in all cases after compiling a packet filter. This was causing a deadlock (complete program hang) if you tried to compile two different filters in a row on the same interface. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7135
svn path=/trunk/; revision=42410
2012-05-04 04:35:43 +00:00
Martin Mathieson 6eb94dd35e Test a return value to avoid an initialised warning from clang.
svn path=/trunk/; revision=42313
2012-04-28 16:18:28 +00:00
Jakub Zawadzki 4253c73d8f Fix sigsegv in filter expression dialog when user clicked on some BASE_CUSTOM field.
svn path=/trunk/; revision=42301
2012-04-27 20:35:17 +00:00
Jakub Zawadzki 31f6e7e35d Don't store protocol field names in Filter Expression dialog.
Using gtk_tree_view_column_set_cell_data_func() and formating string on request 
gives significant speedup (before patch: 12.392ms, after: 9.779ms).

svn path=/trunk/; revision=42291
2012-04-27 13:54:21 +00:00
Guy Harris 177be74688 Get rid of tabs; make white space consistent.
Get rid of gtk_widget_set_size_request() calls - at least on my machine
and GTK+ version, they make some of the items too small to show the full
text.  Let GTK+ figure out how big things have to be - and if that makes
the toolbar too wide, redesign the toolbar.

svn path=/trunk/; revision=42277
2012-04-26 22:11:01 +00:00
Guy Harris 661afd4ba9 Consistently InterCapitalize StatusBar.
Separate "Toolbar" from the toolbar name in the View menu items.

Use "l", rather than "W", as the whatchamacallit for the wireless
toolbar - "W" is already used for "show packet in new window".

svn path=/trunk/; revision=42275
2012-04-26 18:02:04 +00:00
Guy Harris 99a66a0e77 While we're at it, add back the shortcuts, or whatever the heck the
Alt+{letter}+... things are called, for the Expand and Collapse items.

svn path=/trunk/; revision=42274
2012-04-26 17:36:39 +00:00
Anders Broman 47fdd93c3c Restore Accelerators for "Expand Subtree", "Expand All" and "Collapse All".
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7197

svn path=/trunk/; revision=42261
2012-04-26 15:17:01 +00:00
Anders Broman 01abbdf6d2 Add missing ";"
svn path=/trunk/; revision=42222
2012-04-24 14:48:46 +00:00
Michael Tüxen fd356ab4c8 Get it compiling...
svn path=/trunk/; revision=42214
2012-04-23 18:48:00 +00:00
Anders Broman 78cba09c8d Use a crosshair cursor insted of the XOR thingy.
Selected with a define to make it easily reversed if some one does not like it.

svn path=/trunk/; revision=42210
2012-04-23 15:17:31 +00:00
Bill Meier ef1ede5d77 Fix a compile error (missing semi-colon) when building for gtk3
svn path=/trunk/; revision=42209
2012-04-23 15:07:30 +00:00
Anders Broman 6c88c479c6 g_object_unref(cursor) craches pre GTK 3.0 protect it with
#if GTK_CHECK_VERSION(3,0,0)

svn path=/trunk/; revision=42207
2012-04-23 13:39:12 +00:00
ruengeler 0819722ad8 Fix bug #7178 reported by aparan
svn path=/trunk/; revision=42206
2012-04-23 12:34:16 +00:00
Anders Broman 987ce281e4 Use GtkFontChooser if GTK >= 3.2
svn path=/trunk/; revision=42205
2012-04-23 11:10:08 +00:00
ruengeler 618afe1a77 Get rid of GTK warning when START was hit in the "Capture Interfaces Dialog" while a device was hidden.
svn path=/trunk/; revision=42204
2012-04-23 11:06:21 +00:00
Anders Broman cd57bd6bb6 Add casts to make in compile on Windows
svn path=/trunk/; revision=42191
2012-04-22 13:59:28 +00:00
Anders Broman 9e09a1fd0f Use g_object_unref
svn path=/trunk/; revision=42190
2012-04-22 13:54:35 +00:00
Guy Harris 6f1d74b9b1 Another cut-and-pasteo.
svn path=/trunk/; revision=42188
2012-04-21 21:16:54 +00:00
Anders Broman 8bab40a99e More GTK3 adaptations
svn path=/trunk/; revision=42187
2012-04-21 21:13:13 +00:00
Anders Broman c483317006 port gtk_scrollbar_new() gtk_paned_new() gtk_separator_new() to GTK2
svn path=/trunk/; revision=42186
2012-04-21 20:45:35 +00:00
Guy Harris 780061ed74 Fix probable cut-and-pasteo.
svn path=/trunk/; revision=42185
2012-04-21 20:38:18 +00:00
Guy Harris b8087943a1 Clean up indentation (get rid of 4-space tabs).
svn path=/trunk/; revision=42184
2012-04-21 20:13:38 +00:00
Anders Broman 60cb4652e4 gtk_button_box_new() for pre GTK 3.0
svn path=/trunk/; revision=42183
2012-04-21 20:06:51 +00:00
Guy Harris 63040040d2 Clean up indentation - don't use 4-space tabs.
svn path=/trunk/; revision=42182
2012-04-21 19:12:50 +00:00
Guy Harris f16eb8cf14 GTK+ 1.x is no longer supported, and there's no toggle_tree to move any
more; remove a comment.

svn path=/trunk/; revision=42181
2012-04-21 19:07:23 +00:00
Guy Harris 051263c85d "homogeneous" is a Boolean; we can just pass it on to gtk_hbox_new() and
gtk_vbox_new().

svn path=/trunk/; revision=42180
2012-04-21 18:48:49 +00:00
Guy Harris 317769c903 Include "ui/gtk/gui_utils.h" so the ws_gtk_box routines are declared.
svn path=/trunk/; revision=42179
2012-04-21 18:40:43 +00:00
Anders Broman 85118f9213 Replace gtk_vbox_new() and gtk_hbox_new() with ws_gtk_box_new().
svn path=/trunk/; revision=42178
2012-04-21 17:06:30 +00:00
Anders Broman 0a693fb2f6 Missing include
svn path=/trunk/; revision=42177
2012-04-21 16:45:41 +00:00
Anders Broman 03e3fdd79c Replace gtk_vbox_new() and gtk_hbox_new() with ws_gtk_box_new().
svn path=/trunk/; revision=42176
2012-04-21 16:40:14 +00:00
Anders Broman 42310b6eb9 Replace gtk_vbox_new() and gtk_hbox_new() with ws_gtk_box_new().
svn path=/trunk/; revision=42162
2012-04-20 15:28:00 +00:00
Anders Broman b832d1d6ba Replace gtk_vbox_new() and gtk_hbox_new() with ws_gtk_box_new().
svn path=/trunk/; revision=42161
2012-04-20 14:56:24 +00:00
Anders Broman a094f232ea From Martin Kaiser: menus, main window title, icons are not reset when capture is interrupted before any data arrives. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7129
svn path=/trunk/; revision=42149
2012-04-20 05:20:04 +00:00
Jakub Zawadzki 68ec58d385 Fix some: 'cast discards qualifiers from pointer target type' warnings
- Add const qualifier
- Remove some strange casts

svn path=/trunk/; revision=42131
2012-04-18 12:35:36 +00:00
Alexis La Goutte 9380f962a2 Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=42090
2012-04-16 07:59:48 +00:00
Guy Harris 53155a11c0 Get rid of the error code argument to scan_local_interfaces(); nobody
uses it once it's filled in.

From Evan Huus: in scan_local_interfaces(), pass NULL to
capture_interface_list(), as we don't use the error string (and don't
free it, either).

In fill_capture_box(), for CANT_GET_INTERFACE_LIST, include the error
string in the report, and free it, in all cases, when we're done with
it.

svn path=/trunk/; revision=42089
2012-04-15 23:03:58 +00:00
Guy Harris 70f67d065f From Evan Huus: fix a memory leak. Fixes bug 7097.
svn path=/trunk/; revision=42088
2012-04-15 22:21:50 +00:00
Alexis La Goutte 9a988f7de5 Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=42086
2012-04-15 17:27:50 +00:00
Guy Harris cb8edf66a6 From Even Huus: free a strduped string. Fixes bug 7094.
svn path=/trunk/; revision=42074
2012-04-14 18:16:56 +00:00
Guy Harris 6b1c5a9e0d From Evan Huus: free if_string when we're done with it. Fixes bug 7093.
From me: don't bother initializing if_string in its definition, as if
it's used at all it's set to a different value before all uses.

svn path=/trunk/; revision=42073
2012-04-14 18:04:12 +00:00
Anders Broman 7330ec7035 From Evan Huus: Memory leak in scan_local_interfaces. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7086
svn path=/trunk/; revision=42061
2012-04-14 07:44:51 +00:00
Anders Broman ff2840fc2f From Evan Huus: Memory leaks in graph_analysis.c https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7082 changed to not allocating time_str unless needed.
svn path=/trunk/; revision=42060
2012-04-14 07:36:47 +00:00
Guy Harris de42012ffd If we don't even *have* a filter combo box, there's nothing we can check
or colorize; quit before we even *try* to get the link-layer header
type.

If we don't have an active link-layer header type, that probably means
we don't know what link-layer header types the interface provides, which
would be the case if it were a named pipe or an interface we can't open.
Don't crash in that case, just leave the filter combo box uncolored, to
indicate that we have no clue whether the filter is valid or not.

Fixes bug 7049.

svn path=/trunk/; revision=42059
2012-04-14 00:36:30 +00:00
Jakub Zawadzki 8a1dc57c03 Remove doubled semicolons and semicolons outside function.
svn path=/trunk/; revision=42053
2012-04-13 20:22:31 +00:00
Jakub Zawadzki a94826528b Simplify r42030 expression. Thanks!
svn path=/trunk/; revision=42038
2012-04-12 21:56:13 +00:00
Martin Mathieson 27e1c9e248 The last bit of a byte, on its own, needs a mask of 1, rather than 256.
It was not being highlighted in the bits view.

So add % 8 to avoid shifting the single mask bit right out of the byte
we're supposed to be showing...

svn path=/trunk/; revision=42030
2012-04-12 02:14:19 +00:00
Guy Harris c0bfe957b7 There's no __solaris__ predefine for Solaris; just use __sun.
svn path=/trunk/; revision=42011
2012-04-10 18:36:11 +00:00
Guy Harris be2bbb5ecd OK, that doesn't work; on Solaris, try _XOPEN_SOURCE=500, to request
SUSv2, and see if *that* makes the build work.

svn path=/trunk/; revision=42010
2012-04-10 17:56:55 +00:00
Jakub Zawadzki 8fca2eb7e5 Add missing consts.
svn path=/trunk/; revision=42004
2012-04-10 10:20:20 +00:00
Jakub Zawadzki 9d33f00098 Fix 'overflow in implicit constant conversion', make it const.
svn path=/trunk/; revision=41998
2012-04-09 19:12:17 +00:00
Jakub Zawadzki 23494db817 Add missing const attribute to some char *
Fix some "assignment discards qualifiers from pointer target type", etc

svn path=/trunk/; revision=41996
2012-04-09 18:44:10 +00:00
Jakub Zawadzki 9c48f9ca96 Add missing const attribute to some char *
Fix some "assignment discards qualifiers from pointer target type", etc

svn path=/trunk/; revision=41993
2012-04-09 17:53:04 +00:00
Gerald Combs 81334e311a Instead of loading our coordinates from a separate text file via
OpenLayers.Layer.Text, insert them into a JSON array and load them using
OpenLayers.Layer.Vector + OpenLayers.Format.GeoJSON. This should fix the
endpoint map feature on modern browsers.

Switch OpenStreetMap to a simpler map from OSGeo.

svn path=/trunk/; revision=41967
2012-04-05 22:10:53 +00:00
Martin Mathieson 7054049bef Fix test to avoid dividing by 0.0 (was displaying as "-nan" rather than
crashing).

svn path=/trunk/; revision=41948
2012-04-05 00:53:01 +00:00
Jeff Morriss 75c3c92f19 Add a "-build" argument to checkAPIs.pl. Use that argument when building
from makefiles (and thus from the buildbot).

The intention is to be able to tell when a human is running the tool so we
can provide more code-review guidance.

As a starter, enable the "too many proto_tree_add_text() calls" check when
a human is running the tool.

svn path=/trunk/; revision=41943
2012-04-04 20:46:49 +00:00
Jeff Morriss fb207b5d5e Fix CID 613: item_str can't be NULL here so don't check for it being NULL.
svn path=/trunk/; revision=41935
2012-04-04 17:16:16 +00:00
Jeff Morriss 6c4697bc93 Fix CID 614: callsinfo can't be NULL here so don't check for it being NULL.
svn path=/trunk/; revision=41934
2012-04-04 16:57:31 +00:00
Jeff Morriss a95dd5cda7 Fix CID 615: strinfo can't be NULL here so don't check for it being NULL.
svn path=/trunk/; revision=41933
2012-04-04 16:55:14 +00:00
Jeff Morriss cc9f72e246 Fix CID 616: callsinfo can't be NULL here so don't check for it being NULL.
svn path=/trunk/; revision=41932
2012-04-04 16:52:18 +00:00
Jeff Morriss 6610b449b0 Fix CID 617: te can't be NULL here (unless si is NULL in which case we've
got bigger problems) so there's no need to check for it being NULL.

svn path=/trunk/; revision=41931
2012-04-04 16:42:48 +00:00
Michael Tüxen 937df7af18 From Irene Ruengeler: Fix a warning when capturing.
svn path=/trunk/; revision=41897
2012-04-02 17:15:58 +00:00
Anders Broman e12df043a7 If a comment is cleared, remove it from fdata->opt_comment.
svn path=/trunk/; revision=41895
2012-04-02 15:20:54 +00:00
Anders Broman a24133d747 Fix a couple of typos and missing return for GTK 3.
svn path=/trunk/; revision=41894
2012-04-02 12:23:33 +00:00
Anders Broman 0c481e3e96 Introduce utility function to ease GTK3 depcrecated funktion removal.
svn path=/trunk/; revision=41893
2012-04-02 11:35:53 +00:00
Michael Tüxen 16421a31cc More whitespace changes...
svn path=/trunk/; revision=41888
2012-04-01 18:16:15 +00:00
Michael Tüxen fc2377387d Remove waring.
While there: Some whitespace cleanups.

svn path=/trunk/; revision=41887
2012-04-01 17:27:26 +00:00
Anders Broman ba12caf301 From Cal Turney: IO Graph LOAD inaccuracy, intervals not displayed, wrong frames displayed. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6994
svn path=/trunk/; revision=41883
2012-04-01 16:01:12 +00:00
Anders Broman 653a1bb918 From Martin Kaiser: Fix for main_menubar.c:3874: error: set_menu_visible defined but not used
svn path=/trunk/; revision=41868
2012-03-31 09:22:07 +00:00
Stig Bjørlykke 019008548b Recreate the packet list when changing UAT for header fields.
This fixes a crash when changing settings for fields used as a custom column.

svn path=/trunk/; revision=41840
2012-03-30 08:57:57 +00:00
Jeff Morriss eb262d2cc2 As pointed out by Alexis: remove a bunch of set-but-unused variables.
svn path=/trunk/; revision=41839
2012-03-30 01:46:42 +00:00
Martin Mathieson be562947a6 Fix the flag used in a test.
svn path=/trunk/; revision=41835
2012-03-30 00:49:09 +00:00
Martin Mathieson c8933a43d1 Fix a test to avoid setting an invalid display filter.
Reorder some comments to make things a little clearer.

svn path=/trunk/; revision=41834
2012-03-29 23:12:07 +00:00
Stephen Fisher 0dd6243320 Add newline at end of file to fix compilation error.
svn path=/trunk/; revision=41820
2012-03-28 23:54:50 +00:00
Michael Tüxen 20fdcad8b5 From Irene Ruengeler: Fix a crash.
svn path=/trunk/; revision=41818
2012-03-28 11:54:42 +00:00
Michael Tüxen 0949fc1364 Fix compilation.
svn path=/trunk/; revision=41815
2012-03-28 09:26:47 +00:00
Stig Bjørlykke 6e1194d7ba User data is not used in capture_prepare_cb and capture_do_cb.
svn path=/trunk/; revision=41792
2012-03-27 06:57:21 +00:00
Jeff Morriss ce8d32d5bb Get things compiling if we HAVE_AIRPCAP.
svn path=/trunk/; revision=41789
2012-03-27 02:30:51 +00:00
Jeff Morriss b338cf8805 Only enable the OK button if we have an address and a name and name resolution
is enabled.

svn path=/trunk/; revision=41748
2012-03-23 03:14:53 +00:00
Jeff Morriss 48b1c7ae5c As I think Guy said a while back (quoting some HIG): anything you can do in a
popup should also be available through a regular menu.  So, make the
"Manually resolve address" function availble in under View->Name Resolution .
(Yes, technically this is an "Edit"-like action, but it just fits so well
under Name Resolution.)

While there, move "Resolve Name" from main_menu_bar_toggle_action_entries[]
into main_menu_bar_entries[] so it doesn't get a (useless) toggle indicator.
(At least as I understand this function, it's supposed to allow you to tell
Wireshark to go off and try to resolve the names in the current frame;
unfortunately it doesn't seem to actually work.)

svn path=/trunk/; revision=41747
2012-03-23 02:37:25 +00:00
Jeff Morriss 9c1bf7223e Don't mark the file as unsaved unless the capture or packet comments actually changed.
svn path=/trunk/; revision=41744
2012-03-23 01:41:59 +00:00
Martin Mathieson 611dcb0d68 When a TCP graph is summoned, work out how many unique TCP conversations
are present. However, still only create the graph for the first/only
one.

LTE MAC or RLC frames often contain multiple SDUs that are segments of
the same TCP conversation - this avoids the need to find a frame with
only one SDU.

svn path=/trunk/; revision=41721
2012-03-21 12:58:50 +00:00
Michael Tüxen 0f92a3a8d2 From Irene Ruengeler: Restore functinality of last patch.
svn path=/trunk/; revision=41719
2012-03-21 09:54:05 +00:00
Guy Harris 7ee4c2fb40 Make the comment I added, saying what scan_local_interfaces() does, more
accurate.

svn path=/trunk/; revision=41713
2012-03-21 06:37:34 +00:00
Guy Harris 7f5162352f scan_local_interfaces() isn't in capture_opts.c; don't declare it in
capture_opts.h.  (It arguably belongs somewhere other than in a file in
ui/gtk, but, if so, move it there, e.g. to something in ui.)

svn path=/trunk/; revision=41712
2012-03-21 06:31:39 +00:00
Guy Harris 4690f02928 Handle bogus values of the error that *should* be coming from
scan_local_interfaces() (but, currently, isn't, as the code wasn't
correctly restructured).

svn path=/trunk/; revision=41710
2012-03-21 06:20:01 +00:00
Guy Harris 40a034b3f5 Fix 4-space tabs.
svn path=/trunk/; revision=41708
2012-03-21 06:10:17 +00:00
Jeff Morriss 1ee4c9e8a0 activate_link_cb() is only defined and used if we have GTK 2.18 or higher; only prototype it when we have GTK 2.18 or higher.
svn path=/trunk/; revision=41701
2012-03-21 02:42:11 +00:00
Jeff Morriss 075491702b welcome_if_tree_load() is static and only called (and prototyped) if we HAVE_LIBPCAP, so don't define the function unless we HAVE_LIBPCAP.
svn path=/trunk/; revision=41698
2012-03-21 01:22:40 +00:00
Guy Harris 4fe63c565d Well, it doesn't recurse with that code there, but it doesn't fill in
the interface list box, either.  Remove the #if 0 for now.

svn path=/trunk/; revision=41696
2012-03-21 00:44:41 +00:00
Guy Harris 7405ba8145 The chimney stuff is Windows-only (not that we shouldn't offer the
ability to turn offloading off on UN*Xes as well...).

svn path=/trunk/; revision=41695
2012-03-21 00:36:44 +00:00
Guy Harris d43d1c0a6f Recursion, n. See "recursion".
svn path=/trunk/; revision=41694
2012-03-21 00:16:13 +00:00
Guy Harris b551749d28 welcome_if_tree_load() is not used outside ui/gtk/main_welcome.c; make
it static.

svn path=/trunk/; revision=41693
2012-03-21 00:09:45 +00:00
Guy Harris e64375d187 #ifdef out some variables used only if we have libpcap.
svn path=/trunk/; revision=41692
2012-03-21 00:01:42 +00:00
Guy Harris d230d1663f Just put both clear_capture_box() and fill_capture_box() under one
#ifdef HAVE_LIBPCAP/#endif.

svn path=/trunk/; revision=41691
2012-03-20 23:37:23 +00:00
Anders Broman 24298dca48 See if this fixes the OSX build
svn path=/trunk/; revision=41690
2012-03-20 23:03:48 +00:00
Anders Broman 14e0bdf07e See if this fixes the OSX build
svn path=/trunk/; revision=41689
2012-03-20 22:43:44 +00:00
Anders Broman f246d95f88 make it compile on Windows, \main_welcome.c(1024) : warning C4700: uninitialized local variable 'error' used seems like a logical error, hidden by init to zero. Need proper fix
svn path=/trunk/; revision=41688
2012-03-20 22:40:10 +00:00
Michael Tüxen 26dd77f0af From Irene Ruengeler: Make sure we can remove all interfaces and can
add local interfaces when there are none.
From me: Some whitespace cleanups.

svn path=/trunk/; revision=41687
2012-03-20 21:13:28 +00:00
Guy Harris a04472a839 Sort the EXTRA_DIST list.
svn path=/trunk/; revision=41659
2012-03-19 06:31:13 +00:00
Jeff Morriss 90df1a9d94 Set eol-style to native (just to make these files readable on *NIX).
svn path=/trunk/; revision=41654
2012-03-19 01:46:24 +00:00
Jeff Morriss e88f821bc3 Fix path to doxygen_global.cfg
svn path=/trunk/; revision=41652
2012-03-19 01:10:19 +00:00
Bill Meier 2df5dc3d53 From Reinhard Speyerer: Fix several misspellings/typos in Wireshark
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6967

svn path=/trunk/; revision=41645
2012-03-18 22:24:24 +00:00
Bill Meier a7041cacb0 From Bill Schiller: New dissector for the HART/IP protocol
I'm contributing a new dissector for the HART/IP protocol.  This
protocol is specified by the HART Conformance Foundation (HCF).  It is
a standard protocol used in the process control industry.  It
essential wraps the multip-drop serial HART packets in TCP or UDP
packets.  The standard has been approved by the HCF and has been
assigned UDP/TCP port 5094 by IANA.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6961
--This line, and those below,
will be ignored--

M    AUTHORS
M    epan/CMakeLists.txt
M    epan/dissectors/Makefile.common
AM   epan/dissectors/packet-hartip.c
M    ui/gtk/main_menubar.c

svn path=/trunk/; revision=41644
2012-03-18 19:51:39 +00:00
Guy Harris fe37c0ccb8 Add @configure_input@ to a bunch of .in files that didn't have it.
Add $Id$ to those of said files that didn't have it, and fix one $Id to
be $Id$.

svn path=/trunk/; revision=41594
2012-03-16 03:39:51 +00:00
Jeff Morriss 08953cee3a Actually, the Lua-menu-items aren't necessary anyway; remove them.
svn path=/trunk/; revision=41592
2012-03-16 02:47:16 +00:00
Jeff Morriss 80a7287360 Get the Lua menus working again: when adding UI menus, it appears that our
description of existing menus must be accurate: if a name and action are
both specified then the to-be-added-XML must include both the name and the
action.

It appears that the formats given in stat_group_name()'s value_string were
designed to take this into account, but there was no code to separate the menu
name from its action.  Adding that separation is complicated by the fact that
menus are separated by /'s and actions may also contain that character.  To
deal with that, "escape" the /'s in actions by replacing them with #'s.
make_menu_xml() then un-escapes them back into /'s.

There has to be an easier way to do all of this...

svn path=/trunk/; revision=41591
2012-03-16 02:36:32 +00:00
Jeff Morriss a2c94ef9bf Fix menu path typos: Stataistics->Statistics, LUA->Lua
svn path=/trunk/; revision=41588
2012-03-16 02:24:56 +00:00
Jörg Mayer 19ea690e10 Fix:
work/wireshark/svn/trunk/ui/gtk/voip_calls.c:599:9: error: variable ‘voip_calls_graph_list’ set but not used [-Werror=unused-but-set-variable]


svn path=/trunk/; revision=41548
2012-03-14 17:26:49 +00:00
Anders Broman 1d4f630589 voip_calls.c Use the hastable instead, we should do away with the list.
graph_analysis.h Doxygen changes.

svn path=/trunk/; revision=41545
2012-03-14 16:46:59 +00:00
Anders Broman 4c801c8604 VoIP Calls Graph Analysis: Elements not sorted by Time.
Sort the list based on frame number.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6926

svn path=/trunk/; revision=41544
2012-03-14 09:53:33 +00:00
Guy Harris cd1debf183 Add an explicit capture_cb_capture_failed indication for the case where
we weren't even able to start a capture, rather than delivering a fake
"capture start" indication and relying on a later "capture file closed"
indication - for a capture that was never opened in the first place - to
handle GUI cleanups.

Don't deliver any GUI indications in cf_close() if we didn't have a
capture file open in the first place.

Clear the status bar and welcome header if that indication is delivered.

If we start a capture from the command line with the -k flag, don't show
the captured packet information unless the capture actually starts.

svn path=/trunk/; revision=41521
2012-03-13 08:36:25 +00:00
Guy Harris dce6f88487 SystemConfiguration framework, not IOKit?
svn path=/trunk/; revision=41519
2012-03-13 05:02:48 +00:00
Guy Harris b85eebdd7e Suggest a better way of getting the interface type on OS X.
svn path=/trunk/; revision=41518
2012-03-13 05:02:16 +00:00
Guy Harris fa64659e93 Closing a capture file has nothing to do with the list of interfaces on
which to do a live capture; don't clear the latter list when closing the
capture file.

collect_ifaces() should clear out the existing list of interfaces before
filling that list up with the interfaces selected by the user.  In
addition, when it frees up interfaces in that list, it should free up
the strings attached to those interfaces.

svn path=/trunk/; revision=41517
2012-03-13 03:48:27 +00:00
Martin Mathieson d772d2acd2 Add checkboxes to filter for RACH attempts and SRs.
svn path=/trunk/; revision=41500
2012-03-12 13:19:28 +00:00
Martin Mathieson 9560aab8c2 Add a checkbox to filter for RACH attempts.
svn path=/trunk/; revision=41499
2012-03-12 13:18:56 +00:00
Anders Broman b2515852f9 Add doxygen tags.
svn path=/trunk/; revision=41498
2012-03-12 12:18:02 +00:00
Guy Harris 681c29c5d5 Don't close the currently loaded capture file in capture_start(), do so
in its callers; when starting a capture with "wireshark -k", there's no
capture file to close, and closing it might be provoking some UI actions
that cause crashes on Windows.

Don't copy the list of selected interfaces to the list of capture
interfaces in capture_start(), either, do that in the callers; we were
already doing that in one place and, in one of the remaining cases,
namely "wireshark -k", we should do so only if no capture interfaces
were supplied on the command line.  (I.e., the set of interfaces on
which we want to capture depends on where in the UI the capture is being
started.)

svn path=/trunk/; revision=41491
2012-03-11 20:08:54 +00:00
Anders Broman b8fd91e8c1 Add a comments LED
svn path=/trunk/; revision=41487
2012-03-11 19:31:10 +00:00
Stig Bjørlykke 6a724c8d83 Free name string only when used.
svn path=/trunk/; revision=41479
2012-03-11 12:00:13 +00:00
Guy Harris 42df48aab0 capture_opts_add_opt() does just fine at adding an interface to the
capture options, so don't special-case the -i option.

svn path=/trunk/; revision=41477
2012-03-11 07:10:48 +00:00
Guy Harris 5dc7d02ed8 Replace 4-space tabs (and one 8-space tab, the only remaining tab in the
file after replacing the 4-space tabs) with spaces.

svn path=/trunk/; revision=41457
2012-03-10 09:08:03 +00:00
Guy Harris 541dab39eb Replace inconsistent tabs with spaces.
svn path=/trunk/; revision=41456
2012-03-10 09:01:48 +00:00
Jeff Morriss da33d2ef5a Fix up indentation (get rid of 4-space tabs).
svn path=/trunk/; revision=41453
2012-03-09 14:25:30 +00:00
Anders Broman d862ce97e3 Mark an unused parameter as such.
svn path=/trunk/; revision=41452
2012-03-09 14:20:53 +00:00
Anders Broman f6919f2b50 Make packet comments editable from the expert info tab.
svn path=/trunk/; revision=41451
2012-03-09 13:36:29 +00:00
Guy Harris 96aab62f5c Convert 4-space tabs to spaces.
svn path=/trunk/; revision=41442
2012-03-08 20:02:10 +00:00
Gerald Combs de7c1b3ee0 Update the comment icons and tooltips.
svn path=/trunk/; revision=41440
2012-03-08 19:07:02 +00:00
Anders Broman ed05b98afa Add capture_comment_icons.h
svn path=/trunk/; revision=41428
2012-03-08 10:16:30 +00:00
Guy Harris 281f48f7e1 And fix some other ../../image/...s for out-of-tree builds.
svn path=/trunk/; revision=41426
2012-03-08 08:46:52 +00:00
Guy Harris 3c04c817d7 Fix to handle out-of-tree builds - use $(top_srcdir) rather than a
string of ../ items to get to another directory in the source tree, as,
when doing an out-of-tree build, the source tree is a separate tree from
the build tree.

svn path=/trunk/; revision=41425
2012-03-08 08:45:20 +00:00
Anders Broman 376dde9371 summary_dlg.c:419: error: 'dl_description' undeclared (first use in this function)
svn path=/trunk/; revision=41424
2012-03-08 08:07:21 +00:00
Anders Broman 44828083ee Don't show expert info or comments icons unless we have a file loaded
svn path=/trunk/; revision=41423
2012-03-08 08:04:39 +00:00
Anders Broman 839b3e7481 Put a frame around capture comments, don't depend on LIBPCAP to print dl_description or capture filter info
svn path=/trunk/; revision=41422
2012-03-08 07:28:26 +00:00
Anders Broman 368ba24bef Use an OK button rather than save for consistency, wouldapply be more apropriate?
svn path=/trunk/; revision=41421
2012-03-08 06:59:38 +00:00
Jeff Morriss 57f331b9ea Followup to r41415: don't enable *any* of the file operations during a live
capture.

svn path=/trunk/; revision=41416
2012-03-08 02:33:14 +00:00
Jeff Morriss 2f33dbb8f4 As reported by Joerg on -dev: don't enable File->Save if we're still reading
the file (as is the case during a live capture).

Replace tabs with spaces (for consistency with the rest of the file).

svn path=/trunk/; revision=41415
2012-03-08 02:18:12 +00:00
Gerald Combs 52deb5a309 Create some standard definitions for dialog control spacing. Use them in
the comment dialog.

svn path=/trunk/; revision=41412
2012-03-08 01:24:31 +00:00
Jeff Morriss 5b120f36d8 Rename the functions and variables to go along with r41410.
svn path=/trunk/; revision=41411
2012-03-07 23:04:15 +00:00
Jeff Morriss 94e539a193 Use OK, Clear, and Cancel in the comment dialogs (instead of Save, Clear, and Close). This makes the UI similar to our Preferences dialog. And it avoids confusion about whether Save will save the file or not.
svn path=/trunk/; revision=41410
2012-03-07 22:38:02 +00:00
Jeff Morriss 7f96e88fc0 Set File->Save sensitivity after file or packet comments are changed.
svn path=/trunk/; revision=41409
2012-03-07 22:19:06 +00:00
Gerald Combs d839a834cb Update and add icons for capture comments / annotations.
svn path=/trunk/; revision=41406
2012-03-07 20:56:01 +00:00
Anders Broman 6df56f8542 From Martin Kaiser: capture dialogue: unitialized pointer is dereferenced, assigning an arbitrary dlt to a capture interface https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6914
svn path=/trunk/; revision=41369
2012-03-06 09:16:50 +00:00
Anders Broman 34f66b12d8 Use a dedicated treview for packet comments.
svn path=/trunk/; revision=41356
2012-03-05 13:34:55 +00:00
Balint Reczey 104bab54f1 Use 'wireshark' icon from theme
This makes Wireshark able to use SVG icon when it is installed

svn path=/trunk/; revision=41329
2012-03-03 15:40:38 +00:00
Anders Broman 464ec2dcb1 Typo
svn path=/trunk/; revision=41323
2012-03-02 13:53:30 +00:00
Anders Broman ff47bdf96c Use the expert system to show packet comments.
The packet comment widget should be replaced by a ListView with two columns,  packet no and Comment.

svn path=/trunk/; revision=41322
2012-03-02 13:31:16 +00:00
Jeff Morriss 5811471407 Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6891 :
Handle generating selected values for hf's with BASE_DEC_HEX and BASE_HEX_DEC.

svn path=/trunk/; revision=41272
2012-03-01 16:42:49 +00:00
Jeff Morriss 8db7c4d369 #if out setting the help buttons' callbacks to NULL to avoid GLib-Object-CRITICAL warnings.
svn path=/trunk/; revision=41269
2012-03-01 16:03:42 +00:00
Jeff Morriss e3cf120575 Keep track of whether we have a "Edit Capture Comment" dialog open. If we do,
don't open another one.

Make a couple globals static.

svn path=/trunk/; revision=41268
2012-03-01 15:57:39 +00:00
Michael Tüxen 566dc82999 Fix CID 1373.
svn path=/trunk/; revision=41265
2012-03-01 15:10:45 +00:00
Martin Mathieson 59099158b9 Add a checkbox to allow MAC SRs to be included in generated filter
expressions.

svn path=/trunk/; revision=41250
2012-02-29 23:05:27 +00:00
Anders Broman d24fad6371 - Add a LED in the statusbar to indicate that capture comments exists,
clickable to open an edit window.
- Add checks for NULL pointers.

Help with a different color LED possibly with Jeff's (c) in it apreceated.
Should the LED be placed elsewhere or the whole thing done differently?

svn path=/trunk/; revision=41242
2012-02-29 16:51:32 +00:00
Anders Broman 53af6b37b6 Use GTK_COMBO_BOX_TEXT, compile failed when using GTK 2.24.10.
svn path=/trunk/; revision=41235
2012-02-29 11:56:36 +00:00
Anders Broman b3ef8443ab Packet comments are working
svn path=/trunk/; revision=41218
2012-02-28 06:05:32 +00:00
Jeff Morriss 89cfdc3559 Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3315 -
make Save-As/Displayed/All-Packets save not only the displayed packets but
also any other packets needed (e.g., for reassembly) to fully dissect the
displayed packets.

This works only for the "All packets" case; choosing only the Selected packet,
the Marked packets, or a range of packets would require actually storing which
packets depend on which (too much memory) or going through the packet list many
times (too slow).  Also, this behavior is always the case: you can't save the
displayed packets without their dependencies (I don't see why this would be
desirable).

So far this is done for SCTP and things using the reassembly routines (TCP has
been tested).

The Win32 dialog was modified but hasn't been tested yet.

One confusing aspect of the UI is that the Displayed count in the Save-As
dialog does not match the number of displayed packets.  (I tried renaming the
button "Displayed + Dependencies" but it looked too big.)  The tooltip tries
to explain this and the fact that this works only in the All-Packets case;
suggestions for improvement are welcome.


Implementation details:

Dissectors (or the reassembly code) can list frames which were needed to
build the current frame's tree.  If the current frame passes the display
filter then each listed frame is marked as "depended upon" (this takes up the
last free frame_data flag).

When performing a Save-As/Displayed/All-Packets then choose packets which
passed the dfilter _or_ are depended upon.

svn path=/trunk/; revision=41216
2012-02-28 03:19:49 +00:00
Anders Broman ec778bd8f5 Mark the file as unsaved when updating packet comments.
svn path=/trunk/; revision=41208
2012-02-27 15:38:34 +00:00
Chris Maynard 9528902271 Re-apply r40728 and fix Coverity CID 1371 UNINIT again.
svn path=/trunk/; revision=41199
2012-02-27 00:25:41 +00:00
Anders Broman ce30b39aa3 Mark the gile as unsaved if comments are edited
svn path=/trunk/; revision=41198
2012-02-26 19:54:58 +00:00
Anders Broman 38c69c8431 Make it possible to edit capture comments
svn path=/trunk/; revision=41193
2012-02-26 17:04:28 +00:00
Guy Harris 83bf13e1e6 For LANalyzer files, make the "File type name" be the file comment.
Display the file comment in the Summary dialog.

svn path=/trunk/; revision=41188
2012-02-26 10:20:40 +00:00
Guy Harris 30b86b7817 Suppress invalid or non-meaningful statistics - for example, without
time stamps on all packets in a set, you can't determine the start and
end time of the packets in the set (even one timestampless packet throws
the determination off - was that packet before the first time-stamped or
after the last time-stamped packet, or between them?).

svn path=/trunk/; revision=41187
2012-02-26 08:02:02 +00:00
Jeff Morriss bc465f37fc Revisit https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3161
and r39501:

Setting _XOPEN_SOURCE to 600 is only allowed on Solaris 10 if the compiler is
set to C99 mode.  Conversely (and as reported in the bug), simply defining it
(but with no value) is not allowed if the compiler *is* compiling to C99.

So, don't define _XOPEN_SOURCE at all on Solaris.  Keep defining it as 600 on
other OS's as (also) requested in that bug.

Maybe there's a cleaner way to do this but all of this is a "trickery" mess
anyway...

svn path=/trunk/; revision=41182
2012-02-24 20:33:19 +00:00
Bill Meier 605dea0486 CVARSDLL hasn't been used (is undefined) for a while....
svn path=/trunk/; revision=41180
2012-02-24 16:23:38 +00:00
Michael Tüxen acdd01a1d9 From Irene Ruengeler: Always show snaplen.
svn path=/trunk/; revision=41176
2012-02-24 13:13:21 +00:00
Michael Tüxen 64ba56a080 From Irene Ruengeler: Whitespace changes.
svn path=/trunk/; revision=41174
2012-02-24 12:54:15 +00:00
Anders Broman fc42284f1d From Mark Cottrell: Attempting to view an RTP stream analysis graph causes program exit. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6866
svn path=/trunk/; revision=41170
2012-02-24 05:42:40 +00:00
Anders Broman b5a2ba98be Add SHB info to Summary
svn path=/trunk/; revision=41167
2012-02-23 21:29:13 +00:00
Anders Broman 286f3425e7 Have the used interfaces show up if number of interfaces > 0.
(pcapng file).

svn path=/trunk/; revision=41163
2012-02-23 15:40:31 +00:00
Anders Broman 07c039ad17 From Dirk Leinenbach:
Follow TCP IPv6 - wrong hostname.

#BACKPORT
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6861

svn path=/trunk/; revision=41162
2012-02-23 13:24:54 +00:00
Anders Broman 511d403ec2 From Kundok Park:
new_packet_list: crash in add_byte_views from decrypted zigbee data


The cause of the crash I saw was that the add_byte_views() function in
main_proto_draw.c relies on output from previous dissector run while the
function may eventually trigger dissector to run again which wipes out the
previous output.
The patch copies the output of the dissector before calling add_byte_tab() so
that even when add_byte_tab() updates the dissector output, the loop continues
with previous dissector output.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5130

svn path=/trunk/; revision=41158
2012-02-23 11:29:24 +00:00
Michael Tüxen a36c67130f Fix compilation (hopefully).
svn path=/trunk/; revision=41107
2012-02-21 12:56:52 +00:00
Michael Tüxen b1fa4c19e6 From Irene Ruengeler:
* Add support in the GUI for pipes.
* Allow the local interfaces to be rescanned via the GUI.
* Allow remote interfaces to be added and deleted.
The GUI can be extended to support other ways of capturing.

svn path=/trunk/; revision=41105
2012-02-21 11:59:41 +00:00
Guy Harris 1696a933b6 Fix tpo.
svn path=/trunk/; revision=41080
2012-02-20 00:01:21 +00:00
Guy Harris 979db3f4fb Don't run Flex-generated files through checkapi - they use forbidden
APIs such as malloc and free.

svn path=/trunk/; revision=41079
2012-02-19 23:35:19 +00:00
Guy Harris 7100e7a8a0 We already have GENERATED_HEADER_FILES; use that instead of
GENERATED_H_FILES.

If we have DIRTY_GENERATED_C_FILES, use it the same way we use
GENERATED_C_FILES.

GENERATED_FILES is "everything to nuke on a "make maintainer-clean"",
not "everything to put into the distribution".

svn path=/trunk/; revision=41075
2012-02-19 22:41:53 +00:00
Guy Harris b4ffaa9be0 Put back the comment for the rule to generate wireshark-tap-register.c.
svn path=/trunk/; revision=41069
2012-02-19 18:59:08 +00:00
Guy Harris bdab9be898 Rename the (static) library built from stuff in ui/gtk to "libgtkui" in
automake/autoconf and nmake builds, to match the name in CMake builds.

svn path=/trunk/; revision=41058
2012-02-18 20:21:30 +00:00
Michael Tüxen ed68db6e5d Fix tooltips (There is a hidden column).
svn path=/trunk/; revision=41051
2012-02-17 16:48:55 +00:00
Jörg Mayer a206a11e7e include "../util.h" -> include "ui/util.h"
svn path=/trunk/; revision=41048
2012-02-17 12:46:50 +00:00
Michael Tüxen fe30e4ad2e Fix from Irene Ruengeler: Show correct details in the interface dialog on
Windows.

svn path=/trunk/; revision=41042
2012-02-16 20:22:34 +00:00
Anders Broman d0b4fb05f0 From Sean Bright:
Wireshark crashes after editing interface settings from capture options dialog.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6788

svn path=/trunk/; revision=41017
2012-02-13 18:58:14 +00:00
Anders Broman 196e1ab97b Mark an unused parameter.
svn path=/trunk/; revision=41016
2012-02-13 18:50:31 +00:00
Anders Broman c894108aca Edit packet comments
svn path=/trunk/; revision=41013
2012-02-13 17:33:05 +00:00
Anders Broman 6971302a1b Drop count is 64 bits
svn path=/trunk/; revision=41012
2012-02-13 17:31:54 +00:00
Jeff Morriss 95c75fb67a Add edit_packet_comment_dlg.h to the source distribution
svn path=/trunk/; revision=41006
2012-02-12 23:17:01 +00:00
Guy Harris 96b89de3e9 Capitalize the "P" in "Packet" in "Add or Edit Packet Comment". Add
"..." after it, as it pops up a dialog box to let you actually type in a
comment.

Add "Add or Edit Packet Comment" to the menubar's Edit menu.

svn path=/trunk/; revision=41005
2012-02-12 23:09:14 +00:00
Anders Broman ad0df12982 Add a button row.
svn path=/trunk/; revision=41003
2012-02-12 21:15:11 +00:00
Michael Tüxen 8aa280b721 Get it compiling.
svn path=/trunk/; revision=40986
2012-02-12 16:38:47 +00:00
Anders Broman 15d8fe8baa Get the comment and put it in the textview.
svn path=/trunk/; revision=40985
2012-02-12 16:18:25 +00:00
Anders Broman ff4a624dcf Try to make the buildbot happy.
svn path=/trunk/; revision=40983
2012-02-12 15:48:57 +00:00