aboutsummaryrefslogtreecommitdiffstats
path: root/capture.c
AgeCommit message (Collapse)AuthorFilesLines
2005-02-08fix a capture bug if the capture filter wasn't valid to get back to "empty" ↵Ulf Lamping1-2/+2
state. instead of already invoking cf_cb_live_capture_started in capture.c, I've introduced the new event cf_cb_live_capture_prepare which only has to set the main windows title and nothing more. svn path=/trunk/; revision=13355
2005-02-07fix a bug if capturing into named files is usedUlf Lamping1-1/+3
svn path=/trunk/; revision=13345
2005-02-07Move the code to set the title on a window when a capture is in progressGuy Harris1-6/+2
to the "start live capture" callback, and call that from "do_capture()". When opening a capture file, don't pop up the "What do you want to do?" pane when closing any existing file you have open, as we're just going to put the regular view up right after that. svn path=/trunk/; revision=13332
2005-02-06Include <ctype.h> for "isspace()".Guy Harris1-1/+3
#ifdef a variable used only if _WIN32 is defined. svn path=/trunk/; revision=13324
2005-02-06another two steps towards privilege seperation:Ulf Lamping1-6/+238
move another two capture related fields (iface and cfilter) from cfile to capture_opts also move the handling of capture related command line options from main.c to capture.c, that way a future privilege seperated capture program can use the same code to parse it's command line than Ethereal. It might be even possible to share this parser code even with Tethereal, didn't took a closer look at this. svn path=/trunk/; revision=13320
2005-02-06some cleanup of the initial start sequence of Ethereal, filling in ↵Ulf Lamping1-1/+1
capture_opts and alike svn path=/trunk/; revision=13317
2005-02-06fix bugs regarding the capture childUlf Lamping1-1/+1
svn path=/trunk/; revision=13316
2005-02-06instead of initializing the capture_options in main.c, use the new function ↵Ulf Lamping1-0/+35
capture_opts_init svn path=/trunk/; revision=13315
2005-02-05rename kill_capture_child to capture_kill_child to have a common prefixUlf Lamping1-1/+1
split drag and drop support out of main.c into new file drag_and_drop.c, to reduce the size of main.c a bit. Hopefully this won't break unix builds because of missing #include's, I will keep an eye on the buildbot svn path=/trunk/; revision=13308
2005-02-05Put "cf_status_t" back.Guy Harris1-3/+3
svn path=/trunk/; revision=13303
2005-02-04huge cleanup of capture file API (functions in file.c/file.h).Ulf Lamping1-4/+4
This includes: all functions in file.h now have a cf_ prefix, will have doxygen tags, will have the capture_file *cf as the first parameter and I tried to generalize the return values for non trivial functions. Hopefully, I didn't introduced any new bugs, as I had to change a lot of files... svn path=/trunk/; revision=13289
2005-02-04remove #include "globals.h" and access to global cfile, use access functions ↵Ulf Lamping1-12/+11
and capture_opts instead svn path=/trunk/; revision=13283
2005-02-04(some) redesign of capture data structures.Ulf Lamping1-15/+15
don't use global cfile at all but only an untpyed handle to call the cf_... functions in file.c move the save_file member from capture_file to capture_opts, as it's only used while capturing and while preparing it svn path=/trunk/; revision=13276
2005-02-03move capture_file_fd field from capture_file to capture_opts type, as this ↵Ulf Lamping1-4/+4
is the place where it should be svn path=/trunk/; revision=13268
2005-01-16Rename capture_combo_utils.{c,h} to capture_ui_utils.{c,h}, as the codeGuy Harris1-1/+1
in there is for UI functions including, but not limited to, the combo box in capture dialogs. svn path=/trunk/; revision=13061
2005-01-16Use a more descriptive name, if available, for the network interface inGuy Harris1-3/+7
window titles even on UN*X, and if the user's specified a description for an interface, use that rather than the description supplied by libpcap. Put the interface name into the main window title when doing a live capture. svn path=/trunk/; revision=13060
2004-12-29move global capture_child flag into capture_optionsUlf Lamping1-6/+1
svn path=/trunk/; revision=12855
2004-12-29Don't use a global capture_opts in the capturing engine (this isn't a good ↵Ulf Lamping1-32/+52
idea). Do some more "housekeeping" in the capturing part. Hopefully the unspecified forward declaration of capture_options_t in main.h is portable, but buildbot will tell me. This way I need the internals of that struct only at the places I really use it. svn path=/trunk/; revision=12853
2004-11-10bugfix: button in capture info dialog has to stop capturingUlf Lamping1-2/+2
svn path=/trunk/; revision=12506
2004-10-30Move some #defines and #includes around, and add some other #includes,Guy Harris1-57/+6
to make it compile on UN*X. Get rid of some #includes that don't appear to be needed, at least on OS X 10.3 (they might be needed on other platforms). svn path=/trunk/; revision=12453
2004-10-30Get rid of forward declarations of functions not defined in this file.Guy Harris1-12/+0
svn path=/trunk/; revision=12452
2004-10-30split capture_loop from capture.c, some more code cleanupUlf Lamping1-1285/+8
svn path=/trunk/; revision=12451
2004-10-30move quit_after_cap into capture_optsUlf Lamping1-2/+1
svn path=/trunk/; revision=12449
2004-10-30code cleanup: split capture_sync from capture.c into it's own file. Ulf Lamping1-717/+8
That's the part used, when "Update list of packets in real time" is used while capturing. svn path=/trunk/; revision=12445
2004-09-27Move prefs.c and prefs.h into the epan subdirectory.Guy Harris1-1/+1
svn path=/trunk/; revision=12115
2004-09-22If we have "pcap_datalink_val_to_name()", use it when we construct aGuy Harris1-0/+5
"-y" argument for the capture subprocess - the capture subprocess will expect a symbolic value, not a numeric value, if we have "pcap_datalink_name_to_val()". (We assume that if one is present the other will be present as well.) svn path=/trunk/; revision=12064
2004-07-18Move dissectors to epan/dissectors directory.Gilbert Ramirez1-16/+16
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-18Set the svn:eol-style property on all text files to "native", so thatGuy Harris1-1/+1
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-06-30On at least some platforms, a #define of O_BINARY is needed even ifGuy Harris1-1/+5
<fcntl.h> is included, as <fcntl.h> doesn't define it. svn path=/trunk/; revision=11276
2004-06-29define of O_BINARY not needed, if fcntl.h is includedUlf Lamping1-6/+1
other #include related cleanups svn path=/trunk/; revision=11272
2004-06-20added an option to "avoid" the capture info dialog completely.Ulf Lamping1-13/+30
This matters for "update of list in real time" (sync_mode) only, as in normal mode you wouldn't otherwise have the possibility to stop the capture. svn path=/trunk/; revision=11194
2004-05-09From Lars Roland: add support for building a libethereal.dll with MSVC:Guy Harris1-1/+5
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-04-17Failures when capturing should be reported as errors.Guy Harris1-11/+11
svn path=/trunk/; revision=10620
2004-04-13From Jon Oberheide: Add interface name to the capture and ethereal windowMichael Tüxen1-2/+2
while capturing. svn path=/trunk/; revision=10594
2004-03-23Include "packet-ap1394.h" to declare "capture_ap1394()".Guy Harris1-1/+2
svn path=/trunk/; revision=10451
2004-03-23Add support for DLT_APPLE_IP_OVER_IEEE_1394.Guy Harris1-1/+4
svn path=/trunk/; revision=10446
2004-03-13experimental: make usage of pcap_setbuff to increase the kernel buffer sizeUlf Lamping1-1/+15
svn path=/trunk/; revision=10377
2004-03-04capture dialog limits now with units.Ulf Lamping1-2/+2
no gint "wrap around" tests implemented yet svn path=/trunk/; revision=10304
2004-03-04fixed differences between capture GUI frontend and backendUlf Lamping1-51/+76
svn path=/trunk/; revision=10303
2004-03-02implemented capture dialog 3rd (+x) proposalUlf Lamping1-15/+15
svn path=/trunk/; revision=10279
2004-02-28Capturing: "Number of files" switches between normal and multiple mode,Ulf Lamping1-27/+40
"Use ring buffer" switches between multiple single run and real ring buffer svn path=/trunk/; revision=10257
2004-02-21bugfix from previous check inUlf Lamping1-23/+23
svn path=/trunk/; revision=10170
2004-02-21quit_after_cap should be a gboolean, not an int, and it should be initializedUlf Lamping1-6/+6
svn path=/trunk/; revision=10169
2004-02-21rework of capture.c: better seperation of sync and capture pipe by usingUlf Lamping1-279/+352
explicit names and seperated functionality of do_capture(), but no functional change! svn path=/trunk/; revision=10168
2004-02-11Add an "open_failure_alert_box()" routine to pop up an alert box for aGuy Harris1-4/+3
failed attempt to open/create a file. Fix one call to pass the right value for the "for_writing" flag. svn path=/trunk/; revision=10026
2004-02-09bugfix: close capture file again, if empty after capturingUlf Lamping1-1/+11
(bug appears only, if "update list of packets ..." not used) svn path=/trunk/; revision=10017
2004-02-03Tweak the error messages for bad capture filters.Guy Harris1-5/+6
svn path=/trunk/; revision=9974
2004-02-03ups, moved previously missing %s to the right placeUlf Lamping1-3/+3
svn path=/trunk/; revision=9970
2004-02-03Add a missing "%s" to the format string.Guy Harris1-2/+2
svn path=/trunk/; revision=9967
2004-02-03enhanced some dialog messages,Ulf Lamping1-9/+17
close capture file when user told so svn path=/trunk/; revision=9965