File 007-iftop-declare-extern-vars.patch of Package iftop

diff -u a/ui_common.c b/ui_common.c
--- a/ui_common.c	2020-07-10 16:35:47.874322400 +0000
+++ b/ui_common.c	2020-07-10 16:37:16.862322400 +0000
@@ -24,6 +24,12 @@
 char* unit_bits[UNIT_DIVISIONS] =  { "b", "Kb", "Mb", "Gb"};
 char* unit_bytes[UNIT_DIVISIONS] =  { "B", "KB", "MB", "GB"};
 
+sorted_list_type screen_list;
+host_pair_line totals;
+int peaksent, peakrecv, peaktotal;
+hash_type* screen_hash;
+hash_type* service_hash;
+
 extern hash_type* history;
 extern int history_pos;
 extern int history_len;
diff -u a/ui_common.h b/ui_common.h
--- a/ui_common.h	2020-07-10 16:35:47.874322400 +0000
+++ b/ui_common.h	2020-07-10 16:36:41.182322400 +0000
@@ -33,12 +33,12 @@
 
 extern options_t options;
 
-sorted_list_type screen_list;
-host_pair_line totals;
-int peaksent, peakrecv, peaktotal;
+extern sorted_list_type screen_list;
+extern host_pair_line totals;
+extern int peaksent, peakrecv, peaktotal;
 extern history_type history_totals;
-hash_type* screen_hash;
-hash_type* service_hash;
+extern hash_type* screen_hash;
+extern hash_type* service_hash;
 
 void analyse_data(void);
 void screen_list_init(void);
openSUSE Build Service is sponsored by