[PATCH] widget.c: fix slow_terminal declaration



Hello,

This warning is displayed with gcc 3.4.2 ( gcc version 3.4.2 20041017 (Red
Hat 3.4.2-6.fc3) ) on FC3:

widget.c: In function `listbox_new':
widget.c:2099: warning: redundant redeclaration of 'slow_terminal'
widget.c:1659: warning: previous declaration of 'slow_terminal' was here

Changelog:

20041124  Pavel Tsekov  <ptsekov gmx net>

	* warning.c: Fix declaration of `slow_terminal'.
Index: widget.c
===================================================================
RCS file: /cvsroot/mc/mc/src/widget.c,v
retrieving revision 1.117
diff -u -p -r1.117 widget.c
--- widget.c	25 Sep 2004 20:49:15 -0000	1.117
+++ widget.c	24 Nov 2004 09:56:15 -0000
@@ -42,6 +42,7 @@
 #include "key.h"		/* XCTRL and ALT macros  */
 #include "profile.h"	/* for history loading and saving */
 #include "wtools.h"		/* For common_dialog_repaint() */
+#include "main.h"	/* for `slow_terminal' */
 
 static int button_event (Gpm_Event *event, WButton *b);
 
@@ -1656,7 +1657,6 @@ static int listbox_cdiff (WLEntry *s, WL
 static void
 listbox_drawscroll (WListbox *l)
 {
-    extern int slow_terminal;
     int line;
     int i, top;
     int max_line = l->height-1;
@@ -2096,7 +2096,6 @@ WListbox *
 listbox_new (int y, int x, int width, int height, lcback callback)
 {
     WListbox *l = g_new (WListbox, 1);
-    extern int slow_terminal;
 
     init_widget (&l->widget, y, x, height, width,
 		 (callback_fn) listbox_callback,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]