summaryrefslogtreecommitdiff
path: root/iftop.c
diff options
context:
space:
mode:
authorpdw <>2003-10-19 06:44:33 +0000
committerpdw <>2003-10-19 06:44:33 +0000
commit458045923be8a5ff15493a2fd4343f1899a03fa0 (patch)
tree625f07958bf4f2b41da1d0774f8fea26e2a3faed /iftop.c
parent3824538a293966a04eeec220110cc6e84f133312 (diff)
downloadiftop-458045923be8a5ff15493a2fd4343f1899a03fa0.zip
Added initial config file support.
Diffstat (limited to 'iftop.c')
-rw-r--r--iftop.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/iftop.c b/iftop.c
index 6448c8c..0f937e5 100644
--- a/iftop.c
+++ b/iftop.c
@@ -42,6 +42,7 @@
#include "llc.h"
#include "extract.h"
#include "ethertype.h"
+#include "cfgfile.h"
/* ethernet address of interface. */
@@ -517,7 +518,12 @@ int main(int argc, char **argv) {
pthread_t thread;
struct sigaction sa = {};
- options_read(argc, argv);
+ /* read command line options and config file */
+ config_init();
+ options_set_defaults();
+ options_read_args(argc, argv);
+ read_config(options.config_file);
+ options_make();
sa.sa_handler = finish;
sigaction(SIGINT, &sa, NULL);