Commit Graph

98 Commits

Author SHA1 Message Date
Guy Harris 92552c2d76 Get rid of a bunch of "Ethereal"s and "ethereal"s in comments, GUI
strings, and function names.

svn path=/trunk/; revision=18205
2006-05-22 07:29:40 +00:00
Ronnie Sahlberg 89f022b12b name change
svn path=/trunk/; revision=18197
2006-05-21 05:12:17 +00:00
Guy Harris 84aef00bad Move the file selection dialog routines to file_dlg.c, and give it a
header file.

#if 0 out some includes; if none of the builds have a problem with
that, I'll remove them.

svn path=/trunk/; revision=18036
2006-04-30 01:47:58 +00:00
Jaap Keuter 7f5fc8b8d9 Workaround for bug 852. Force a line break so that the text view doesn't blow up on excessive long lines.
svn path=/trunk/; revision=18001
2006-04-26 06:37:46 +00:00
Ulf Lamping c858e7e993 add a help button to the "Follow TCP Stream" dialog (and use standard button row for it too)
svn path=/trunk/; revision=17931
2006-04-20 19:58:50 +00:00
Ulf Lamping e58b233aa5 fix capitalization to follow GNOME HIG
svn path=/trunk/; revision=17887
2006-04-17 21:13:09 +00:00
Guy Harris c32311dcd5 Add tempfile.h to the list of headeer files. That was the problem, not
the pathname in the #include.

svn path=/trunk/; revision=17280
2006-02-13 01:30:03 +00:00
Guy Harris 3674669ad6 Look for "tempfile.h" in the top-level directory.
svn path=/trunk/; revision=17279
2006-02-12 23:48:34 +00:00
Guy Harris 4d8d477018 Move create_tempfile() to tempfile.c out of util.c. This means dumpcap
no longer needs util.c, so it no longer includes routines that use
host_ip_af(), so it no longer needs to define its own host_ip_af().

That also means dumpcap.c no longer needs to include <sys/socket.h>.

svn path=/trunk/; revision=17278
2006-02-12 21:52:18 +00:00
Jörg Mayer c24e4dd597 Peter Kjellerstedt:
GTK_WRAP_WORD_CHAR does not exist in old versions of GTK2+
(2.2.1 and earlier).  The following patch should make it
compile again (solution borrowed from GAIM).


svn path=/trunk/; revision=17199
2006-02-07 10:22:41 +00:00
Jörg Mayer 7719a3b803 Jaap Keuter:
Browsing through the wishlist I came across this old one by Steve Brown:
------8<------
The GTK1 UI wordwraps assembled TCP streams, the GTK2 UI doesn't, but
should also. Not wrapping makes reading any protocol that lacks linebreaks
virtually impossible (XML, etc.) as it all ends up on one line. I'm tired
of having to install the GTK1 UI :P
------8<------
It seems like a simple request. The oneliner patch implements this wish.
Maybe someone feels the need to make it a preference or selectable.


svn path=/trunk/; revision=16939
2006-01-03 23:45:58 +00:00
Ulf Lamping c3187174bf replace *a lot* of file related calls by their GLib counterparts. This is necessary for the switch to GTK 2.6 (at least on WIN32).
to do this, I've added file_util.h to wiretap (would file_compat.h be a better name?), and provide compat_macros like eth_open() instead of open(). While at it, move other file related things there, like #include <io.h>, definition of O_BINARY and alike, so it's all in one place.

deleted related things from config.h.win32

As of these massive changes, I'm almost certain that this will break the Unix build. I'll keep an eye on the buildbot so hopefully everything is working again soon.

svn path=/trunk/; revision=16403
2005-11-06 22:43:25 +00:00
Guy Harris a0e68da918 Add a "register_dfilter_stat()", to register stats that take a display
filter as an argument on the command line and have a dialog box to enter
the display filter through the GUI.  Use it for all stats using
"gtk_tap_dfilter_dlg_cb()".

Add a top-level "stat_menu.h" file to declare "REGISTER_STAT_GROUP_E"
for the benefit of the declaration of "register_dfilter_stat()" in the
top-level "tap_dfilter_dlg.h".  Rename the "stat_menu.h" in the gtk
directory to "gtk_stat_menu.h", so as not to have two headers with the
same name.

Get rid of headers not declaring any functions not being used in the
module.

svn path=/trunk/; revision=15493
2005-08-21 09:48:27 +00:00
Ulf Lamping eafbbbcabb renamed ui_util.c/.h to gui_utils.c/.h to prevent confusion with identical named ui_util.h in / dir
svn path=/trunk/; revision=15465
2005-08-20 12:09:48 +00:00
Guy Harris b2807e2ab6 Move the APIs for registering and processing "-z" command-line arguments
and "Statistics" menu items into "stat.h" and "stat.c", to separate them
from the core tapping APIs.  A tap could conceivably not register as a
"-z" command-line argument or "Statistics" menu item, and a stat could
conceivably not be implemented as a tap, and dissectors that implement
tapping points don't need the UI-related stuff from "stat.h", they just
want the tap-related stuff in <epan/tap.h>.

svn path=/trunk/; revision=15427
2005-08-19 09:29:41 +00:00
Lars Roland ec9ca01616 Move the following files from /trunk to /trunk/epan:
asn1.[ch]
follow.[ch]
ptvcursor.[ch]
reassemble.[ch]
xmlstub.[ch]

fix #include statements accordingly.

svn path=/trunk/; revision=13366
2005-02-09 23:38:00 +00:00
Ulf Lamping 7eff647262 add tooltips to the dialogs radio buttons
svn path=/trunk/; revision=13259
2005-02-03 20:44:19 +00:00
Guy Harris 93426174ef Writing the raw data of a TCP stream to a file isn't printing it, so
don't use the print mechanism for that - do the writing directly in the
"follow stream" code.

Use "size_t" for character counts.

Make the "hexchars" array static and const, as it's not written to, and
there's probably no point in copying it to the stack (unless that
improves cache locality).

There's no need to explain why we're subtracting the number of bytes
actually read, rather than the number of bytes asked for, from the data
length.

Note an issue with printing lines.

svn path=/trunk/; revision=13240
2005-02-02 10:28:51 +00:00
Ronnie Sahlberg b4d53ed380 from chris eagle
add radiobutton to allow saving raw tcpstreams


these radiobuttons should, by someone that uses, this feature be changed into
a menu instead.



svn path=/trunk/; revision=13236
2005-02-02 08:50:40 +00:00
Guy Harris 7e58bd88ca Cast the values passed to the <ctype.h> macros so as to avoid
sign-extending 8-bit characters.

svn path=/trunk/; revision=12922
2005-01-02 00:23:50 +00:00
Guy Harris 097877f306 Don't redisplay the "Follow TCP Stream" window on every toggle event for
the display style (ASCII/EBCDIC/char[]/hex) radio button set - pushing a
radio button generates *two* events, one for the button that gets turned
off and one for the button that gets turned on.

svn path=/trunk/; revision=12530
2004-11-16 08:21:32 +00:00
Guy Harris eaadcc4c62 Move various tables into the epan directory.
svn path=/trunk/; revision=12130
2004-09-29 00:52:45 +00:00
Guy Harris bbe7f89742 Move prefs.c and prefs.h into the epan subdirectory.
svn path=/trunk/; revision=12115
2004-09-27 22:55:15 +00:00
Guy Harris ac982aa7a5 Move the stuff to handle ASCII <-> EBCDIC conversions to
"epan/charsets.c"; other character set translation code should perhaps
go there as well.

svn path=/trunk/; revision=11958
2004-09-10 22:59:37 +00:00
Guy Harris 3a583aeb59 From Albert Chin: rename resolv.{ch} to addr_resolv.{ch}, so that an
include of <resolv.h> in any system header file gets the system
<resolv.h> (needed for builds on Tru64 with GTK+ 1.2[.x]).

svn path=/trunk/; revision=11615
2004-08-06 19:57:49 +00:00
Guy Harris 5a3ab160c1 Make some generic print routines that take, as an argument, a pointer to
a structure containing a pointer to print operations for that object and
a pointer to the private subclass-dependent data for that object, with
subclasses for text and PostScript, and use those rather than the old
scheme where a print format was passed as an argument - or where (as in
the case of printing summary information in Tethereal) we just printed
as text even if "-T ps" was selected.

Check whether those routines succeed or get an I/O error writing output.

Clean up indentation.

svn path=/trunk/; revision=11514
2004-07-25 08:53:38 +00:00
Guy Harris 34de3c15d9 Have "gtk/color_utils.c" contain routines with toolkit-independent APIs,
but toolkit-dependent implementations, for manipulating colors, and have
"gtk/color_utils.h" declare them (the header file should eventually be
moved to the top-level directory).  Move the routines to convert between
GdkColor and color_t out of there into "colors.c", and move their
declarations into "colors.h", as their APIs are toolkit-dependent.

Have the first such routine be a "create_color()" routine, which takes
RGB values and initializes a "color_t", including doing any
toolkit-dependent work necessary for that; use that in the
"gtk/color_filters.c" code (the goal is to remove as many of the toolkit
dependencies as possible from that code, and move it to the top-level
directory).

svn path=/trunk/; revision=11497
2004-07-24 00:35:13 +00:00
Gilbert Ramirez 669db206cb Move dissectors to epan/dissectors directory.
Also move ncp222.py, x11-fields, process-x11-fields.pl,
make-reg-dotc, and make-reg-dotc.py.

Adjust #include lines in files that include packet-*.h
files.

svn path=/trunk/; revision=11410
2004-07-18 18:06:47 +00:00
Guy Harris 8a8b883450 Set the svn:eol-style property on all text files to "native", so that
they have LF at the end of the line on UN*X and CR/LF on Windows;
hopefully this means that if a CR/LF version is checked in on Windows,
the CRs will be stripped so that they show up only when checked out on
Windows, not on UN*X.

svn path=/trunk/; revision=11400
2004-07-18 00:24:25 +00:00
Guy Harris fe1b0f99c4 In the GTK+ code, move the redefinition of "isprint()" to
"gtk/isprint.h", and include that in "follow_dlg.c" (which wasn't
including "gtkglobals.h" and thus wasn't getting the redefinition) and
"proto_draw.c" (which was including "gtkglobals.h" but now needs to
include "isprint.h" as well).

svn path=/trunk/; revision=11355
2004-07-09 23:02:38 +00:00
Jörg Mayer 4bbb32eaaa The patch to fix the race condition introduced by using tmpnam replaced
insecure code by not-working code.  As I currently lack the time to fix
this properly until Monday as the earliest possible date I undo the patch.

Please note that Ethereal should not be used on multiuser systems with
untrusted users until a proper fix has been applied.

svn path=/trunk/; revision=11263
2004-06-29 03:27:52 +00:00
Jörg Mayer 0195deceae tmpnam() really should not be used for security reasons.
Replace it where used and update README.developer accordingly.

svn path=/trunk/; revision=11235
2004-06-25 07:04:03 +00:00
Ulf Lamping 25e6749eb4 move font related stuff to new file font_utils.c/.h
do some font related renaming/code cleanup

svn path=/trunk/; revision=11166
2004-06-17 16:35:26 +00:00
Ulf Lamping 14bf83c340 add details for doxygen, various code cleanups as a result of this
svn path=/trunk/; revision=11052
2004-06-01 17:33:37 +00:00
Ulf Lamping 504edf02ec enable postcript printing if selected in prefs,
correctly remove temporary file on close dialog

svn path=/trunk/; revision=11026
2004-05-27 23:09:09 +00:00
Ulf Lamping e57142b214 bugfixes: fixed printing on win32,
and convert none printable characters, so printing will work on binary output as well
(like in the GUI output)

svn path=/trunk/; revision=11025
2004-05-27 21:55:59 +00:00
Ulf Lamping e22528662a bugfix: don't try to destroy a window, when it's already being destroyed
svn path=/trunk/; revision=11016
2004-05-27 16:48:36 +00:00
Guy Harris bf55bfd7eb Don't compile in "follow_save_as_destroy_cb()" for GTK+ 2.4 and later,
as it's not used.

svn path=/trunk/; revision=11011
2004-05-26 21:23:20 +00:00
Ulf Lamping 7d37fc9d23 more code cleanup from dialog things:
changed window_xy (dialog) function calling in a lot of gtk files
cleanup of file selection code
cleanup in dlg_utils/file_dlg/ui_util
Please report any problems!!!

svn path=/trunk/; revision=11003
2004-05-26 03:49:24 +00:00
Ulf Lamping d6eeb0936d going to have a standard behaviour of the dialogs
(including remebering of the dialog size in recent file).
for a first step, I replaced all window_new() calls from dialogs
into dlg_window_new() ones, and removed all gtk_window_set_position
calls, this should be done in a more generalized way

svn path=/trunk/; revision=10964
2004-05-22 19:56:19 +00:00
Guy Harris 15af0f656f From Lars Roland: add support for building a libethereal.dll with MSVC:
add a config.nmake option to control whether to build
	libethereal.dll or not;

	remove "./wiretap" from PATH to prevent problems due to
	wrongly-loaded files;

	build dissector.lib with MSVC;

	move "print.c" and "ps.c" to the dissector helpers, as "print.c"
	imports variables from packet-frame.c and packet-data.c, which
	are in libethereal;

	move "g711.c" out of the dissector helpers, as they're used only
	by Ethereal in a tap, not in Tethereal or in any dissector;

	add a .def file for libethereal;

	arrange to declare global variables exported from libethereal
	with "__declspec(dllimport)" when building programs that import
	those variables;

	update the NSIS installer.

Make the "configure" script define ETH_VAR_IMPORT as "extern".

svn path=/trunk/; revision=10834
2004-05-09 10:03:41 +00:00
Olivier Biot f1c30d72c8 Part 2 of Ulf's print update.
svn path=/trunk/; revision=10654
2004-04-21 00:48:22 +00:00
Gerald Combs dba256262a Make the hex dump byte counter a guint32, so that we don't wrap prematurely.
svn path=/trunk/; revision=10578
2004-04-09 19:44:27 +00:00
Guy Harris 29c644691b Make "file_selection_new()" take as its second argument an
Ethereal-defined indication of the action (open vs. save), regardless of
whether we're building for GTK+ >= 2.4 or not; we just ignore the
argument in pre-2.4 GTK+.

Use "file_selection_new()" rather than #if'ed code to use it or
"gtk_file_chooser_dialog_new()"  for GTK+ >= 2.4 and
"gtk_file_selection_new()" or it for pre-2.4 GTK+.

Add a "file_selection_set_current_folder()" routine that does the
appropriate thing depending on whether we're GTK+ >= 2.4 or not, and use
that rather than #if'ed code to use
"gtk_file_chooser_set_current_folder()" or
"gtk_file_selection_set_filename()".

svn path=/trunk/; revision=10511
2004-03-29 22:40:58 +00:00
Olivier Abad cd19c5baf8 Use the new GtkFileChooserDialog when built with gtk+ 2.4
svn path=/trunk/; revision=10502
2004-03-27 11:16:58 +00:00
Ulf Lamping 7b62a629e8 replaced sprintf / snprintf by g_snprintf,
various other string related changes

svn path=/trunk/; revision=10373
2004-03-13 15:15:26 +00:00
Ulf Lamping 47b176f983 various string related changes
svn path=/trunk/; revision=10372
2004-03-13 14:07:14 +00:00
Guy Harris 164c3ea936 Get rid of a debugging printf.
svn path=/trunk/; revision=10238
2004-02-25 21:05:09 +00:00
Guy Harris 6064ef84c2 Add a "force" argument to "filter_packets()" and
"main_filter_packets()", to force the filtering to be done even if the
filter is the same as the current one; this is necessary in order to
make sure "Follow TCP Stream" gets the packets processed even if you're
filtering the stream that's currently filtered in.

svn path=/trunk/; revision=10209
2004-02-23 22:48:52 +00:00
Ulf Lamping ed6148660b statistics menu redesigned, now looking more like the former menu,
items now again grouped by function, not by ISO layer

svn path=/trunk/; revision=10202
2004-02-23 19:19:39 +00:00