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

[or-cvs] log when exit situation is hopeless.



Update of /home/or/cvsroot/src/or
In directory moria.mit.edu:/tmp/cvs-serv13714/src/or

Modified Files:
	onion.c 
Log Message:
log when exit situation is hopeless.

Index: onion.c
===================================================================
RCS file: /home/or/cvsroot/src/or/onion.c,v
retrieving revision 1.121
retrieving revision 1.122
diff -u -d -r1.121 -r1.122
--- onion.c	30 Jan 2004 23:43:17 -0000	1.121
+++ onion.c	4 Feb 2004 22:35:58 -0000	1.122
@@ -349,6 +349,9 @@
   } else {
     /* Either there are no pending connections, or no routers even seem to
      * possibly support any of them.  Choose a router at random. */
+    if (best_maybe_support == -1) {
+      log(LOG_WARN, "All routers are down or middleman -- choosing a doomed exit at random.");
+    }
     for(i = best_maybe_support_idx; i < dir->n_routers; i++)
       if(n_supported[i] != -1)
         smartlist_add(sl, dir->routers[i]);