[or-cvs] Appease verbose GCC warnings.

Nick Mathewson nickm at seul.org
Mon Jun 20 09:38:31 UTC 2005


Update of /home/or/cvsroot/tor/src/or
In directory moria:/tmp/cvs-serv1269/src/or

Modified Files:
	control.c main.c 
Log Message:
Appease verbose GCC warnings.

Index: control.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/control.c,v
retrieving revision 1.95
retrieving revision 1.96
diff -u -d -r1.95 -r1.96
--- control.c	19 Jun 2005 22:38:36 -0000	1.95
+++ control.c	20 Jun 2005 09:38:29 -0000	1.96
@@ -1543,6 +1543,8 @@
 {
   char *desc;
   int v0 = STATE_IS_V0(conn->state);
+  const char *msg=NULL;
+
   if (v0)
     desc = (char*)body;
   else {
@@ -1551,7 +1553,6 @@
     read_escaped_data(cp, len-(cp-body), 1, &desc);
   }
 
-  const char *msg=NULL;
   switch (router_load_single_router(desc, &msg)) {
   case -1:
     if (!msg) msg = "Could not parse descriptor";

Index: main.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/main.c,v
retrieving revision 1.519
retrieving revision 1.520
diff -u -d -r1.519 -r1.520
--- main.c	19 Jun 2005 08:35:46 -0000	1.519
+++ main.c	20 Jun 2005 09:38:29 -0000	1.520
@@ -893,7 +893,7 @@
 /** Called when a possibly ignorable libevent error occurs; ensures that we
  * don't get into an infinite loop by ignoring too many errors from
  * libevent. */
-int
+static int
 got_libevent_error(void)
 {
   if (++n_libevent_errors > 8) {



More information about the tor-commits mailing list