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

[or-cvs] Delete trailing whitespace and expand tabs; remove unused a...



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

Modified Files:
	circuit.c connection.c connection_edge.c directory.c dns.c 
	routerlist.c test.c tree.h 
Log Message:
Delete trailing whitespace and expand tabs; remove unused aes decrypt code

Index: circuit.c
===================================================================
RCS file: /home/or/cvsroot/src/or/circuit.c,v
retrieving revision 1.190
retrieving revision 1.191
diff -u -d -r1.190 -r1.191
--- circuit.c	7 Apr 2004 19:22:55 -0000	1.190
+++ circuit.c	7 Apr 2004 19:57:39 -0000	1.191
@@ -1152,7 +1152,7 @@
       break;
     case CIRCUIT_PURPOSE_S_CONNECT_REND:
       /* at Bob, connecting to rend point */
-      // 
+      //
       break;
   }
 }

Index: connection.c
===================================================================
RCS file: /home/or/cvsroot/src/or/connection.c,v
retrieving revision 1.192
retrieving revision 1.193
diff -u -d -r1.192 -r1.193
--- connection.c	5 Apr 2004 00:47:47 -0000	1.192
+++ connection.c	7 Apr 2004 19:57:39 -0000	1.193
@@ -247,7 +247,7 @@
     if (conn->hold_open_until_flushed) {
       assert(conn->marked_for_close);
       if (now - conn->timestamp_lastwritten >= 15) {
-        log_fn(LOG_WARN,"Giving up on marked_for_close conn that's been flushing for 15s (fd %d, type %s, state %d).", 
+        log_fn(LOG_WARN,"Giving up on marked_for_close conn that's been flushing for 15s (fd %d, type %s, state %d).",
                conn->s, CONN_TYPE_TO_STRING(conn->type), conn->state);
         conn->hold_open_until_flushed = 0;
       }
@@ -449,7 +449,7 @@
 
   if(options.DirPort) {
     listener_close_if_present(CONN_TYPE_DIR_LISTENER);
-    if(connection_create_listener(options.DirBindAddress, 
+    if(connection_create_listener(options.DirBindAddress,
                                   (uint16_t) options.DirPort,
                                   CONN_TYPE_DIR_LISTENER) < 0)
       return -1;

Index: connection_edge.c
===================================================================
RCS file: /home/or/cvsroot/src/or/connection_edge.c,v
retrieving revision 1.147
retrieving revision 1.148
diff -u -d -r1.147 -r1.148
--- connection_edge.c	7 Apr 2004 19:14:45 -0000	1.147
+++ connection_edge.c	7 Apr 2004 19:57:39 -0000	1.148
@@ -1158,7 +1158,7 @@
       log_fn(LOG_INFO,"Resolve failed (%s).", n_stream->address);
       /* Set the state so that we don't try to remove n_stream from a DNS
        * pending list. */
-      n_stream->state = EXIT_CONN_STATE_RESOLVEFAILED; 
+      n_stream->state = EXIT_CONN_STATE_RESOLVEFAILED;
       connection_mark_for_close(n_stream, END_STREAM_REASON_RESOLVEFAILED);
       break;
     case 0: /* resolve added to pending list */

Index: directory.c
===================================================================
RCS file: /home/or/cvsroot/src/or/directory.c,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -d -r1.83 -r1.84
--- directory.c	3 Apr 2004 03:33:57 -0000	1.83
+++ directory.c	7 Apr 2004 19:57:39 -0000	1.84
@@ -91,7 +91,7 @@
       return;
     }
 
-    conn->state = DIR_CONN_STATE_CLIENT_SENDING; 
+    conn->state = DIR_CONN_STATE_CLIENT_SENDING;
     connection_set_poll_socket(conn);
     connection_start_reading(conn);
   }

Index: dns.c
===================================================================
RCS file: /home/or/cvsroot/src/or/dns.c,v
retrieving revision 1.72
retrieving revision 1.73
diff -u -d -r1.72 -r1.73
--- dns.c	29 Mar 2004 19:57:50 -0000	1.72
+++ dns.c	7 Apr 2004 19:57:39 -0000	1.73
@@ -364,7 +364,7 @@
     pend->conn->addr = resolve->addr;
     if(resolve->state == CACHE_STATE_FAILED) {
       /* prevent double-remove */
-      pend->conn->state = EXIT_CONN_STATE_RESOLVEFAILED; 
+      pend->conn->state = EXIT_CONN_STATE_RESOLVEFAILED;
       pendconn = pend->conn; /* don't pass complex things to the
                                 connection_mark_for_close macro */
       connection_mark_for_close(pendconn, END_STREAM_REASON_RESOLVEFAILED);

Index: routerlist.c
===================================================================
RCS file: /home/or/cvsroot/src/or/routerlist.c,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -d -r1.55 -r1.56
--- routerlist.c	7 Apr 2004 19:46:27 -0000	1.55
+++ routerlist.c	7 Apr 2004 19:57:39 -0000	1.56
@@ -123,7 +123,7 @@
                                 const char *start_str, const char *end_str);
 static void token_free(directory_token_t *tok);
 static smartlist_t *find_all_exitpolicy(smartlist_t *s);
-static directory_token_t *find_first_by_keyword(smartlist_t *s, 
+static directory_token_t *find_first_by_keyword(smartlist_t *s,
                                                 directory_keyword keyword);
 static int tokenize_string(const char *start, const char *end,
                            smartlist_t *out, int is_dir);
@@ -607,7 +607,7 @@
 }
 
 int router_exit_policy_rejects_all(routerinfo_t *router) {
-  return router_compare_addr_to_exit_policy(0, 0, router->exit_policy) 
+  return router_compare_addr_to_exit_policy(0, 0, router->exit_policy)
     == ADDR_POLICY_REJECTED;
 }
 
@@ -618,9 +618,9 @@
   if (!strptime(cp, "%Y-%m-%d %H:%M:%S", &st_tm)) {
     log_fn(LOG_WARN, "Published time was unparseable"); return -1;
   }
-#else 
+#else
   unsigned int year=0, month=0, day=0, hour=100, minute=100, second=100;
-  if (sscanf(cp, "%u-%u-%u %u:%u:%u", &year, &month, 
+  if (sscanf(cp, "%u-%u-%u %u:%u:%u", &year, &month,
                 &day, &hour, &minute, &second) < 6) {
         log_fn(LOG_WARN, "Published time was unparseable"); return -1;
   }
@@ -645,7 +645,7 @@
  * If pkey is provided, we check the directory signature with pkey.
  */
 int /* Should be static; exposed for unit tests */
-router_get_routerlist_from_directory_impl(const char *str, 
+router_get_routerlist_from_directory_impl(const char *str,
                                           routerlist_t **dest,
                                           crypto_pk_env_t *pkey)
 {
@@ -690,7 +690,7 @@
 
   tok = smartlist_get(tokens,0);
   if (tok->tp != K_SIGNED_DIRECTORY) {
-    log_fn(LOG_WARN, "Directory doesn't start with signed-directory."); 
+    log_fn(LOG_WARN, "Directory doesn't start with signed-directory.");
     goto err;
   }
 
@@ -699,7 +699,7 @@
     goto err;
   }
   assert(tok->n_args == 1);
-  
+
   if (parse_time(tok->args[0], &published_on) < 0) {
      goto err;
   }
@@ -712,10 +712,10 @@
     log_fn(LOG_WARN, "Invalid recommended-software line"); goto err;
   }
   versions = tor_strdup(tok->args[0]);
-  
+
   if (!(tok = find_first_by_keyword(tokens, K_RUNNING_ROUTERS))) {
     log_fn(LOG_WARN, "Missing running-routers line from directory.");
-    goto err;    
+    goto err;
   }
 
   n_good_nicknames = tok->n_args;
@@ -751,7 +751,7 @@
   }
   tok = smartlist_get(tokens,0);
   if (strcmp(tok->object_type, "SIGNATURE") || tok->object_size != 128) {
-    log_fn(LOG_WARN, "Bad object type or length on directory signature"); 
+    log_fn(LOG_WARN, "Bad object type or length on directory signature");
     goto err;
   }
   if (pkey) {
@@ -930,8 +930,8 @@
   } else {
     log_fn(LOG_WARN,"Wrong # of arguments to \"router\"");
     goto err;
-  }  
-    
+  }
+
   tok = find_first_by_keyword(tokens, K_PORTS);
   if (tok && ports_set) {
     log_fn(LOG_WARN,"Redundant ports line");
@@ -946,7 +946,7 @@
     router->dir_port = atoi(tok->args[2]);
     ports_set = 1;
   }
-  
+
   tok = find_first_by_keyword(tokens, K_BANDWIDTH);
   if (tok && bw_set) {
     log_fn(LOG_WARN,"Redundant bandwidth line");
@@ -1041,7 +1041,7 @@
 
   goto done;
   return router;
-  
+
  err:
   routerinfo_free(router);
   router = NULL;
@@ -1098,7 +1098,7 @@
 
 /* Given a K_ACCEPT or K_REJECT token and a router, create a new exit_policy_t
  * corresponding to the token, and add it to 'router' */
-static int 
+static int
 router_add_exit_policy(routerinfo_t *router, directory_token_t *tok) {
 
   struct exit_policy_t *tmpe, *newe;
@@ -1256,7 +1256,7 @@
        tok->tp = _ERR;                                  \
        tok->error = msg;                                \
        goto done_tokenizing; } while (0)
- 
+
   tok = tor_malloc_zero(sizeof(directory_token_t));
   tok->tp = _ERR;
 
@@ -1264,7 +1264,7 @@
   if (!**s) {
     tok->tp = _EOF;
     return tok;
-  } 
+  }
   next = find_whitespace(*s);
   if (!next) {
     tok->error = "Unexpected EOF"; return tok;
@@ -1394,7 +1394,7 @@
     case OBJ_OK:
       break;
     }
-  
+
  done_tokenizing:
 
 #if 0
@@ -1423,8 +1423,8 @@
 #undef RET_ERR
 }
 
-static int 
-tokenize_string(const char *start, const char *end, smartlist_t *out, 
+static int
+tokenize_string(const char *start, const char *end, smartlist_t *out,
                 int is_dir)
 {
   const char **s;
@@ -1440,7 +1440,7 @@
     smartlist_add(out, tok);
     *s = eat_whitespace(*s);
   }
-  
+
   return 0;
 }
 

Index: test.c
===================================================================
RCS file: /home/or/cvsroot/src/or/test.c,v
retrieving revision 1.76
retrieving revision 1.77
diff -u -d -r1.76 -r1.77
--- test.c	7 Apr 2004 19:46:27 -0000	1.76
+++ test.c	7 Apr 2004 19:57:39 -0000	1.77
@@ -608,7 +608,7 @@
   char **names;
   int i,num;
 
-  names = parse_nickname_list("  foo bar	 baz quux  ", &num);
+  names = parse_nickname_list("  foo bar\t baz quux  ", &num);
   test_eq(num,4);
   test_streq(names[0],"foo");
   test_streq(names[1],"bar");

Index: tree.h
===================================================================
RCS file: /home/or/cvsroot/src/or/tree.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- tree.h	31 Dec 2002 15:05:07 -0000	1.1
+++ tree.h	7 Apr 2004 19:57:39 -0000	1.2
@@ -83,7 +83,7 @@
 	SPLAY_RIGHT(tmp, field) = (head)->sph_root;			\
 	(head)->sph_root = tmp;						\
 } while (0)
-	
+
 #define SPLAY_ROTATE_LEFT(head, tmp, field) do {			\
 	SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(tmp, field);	\
 	SPLAY_LEFT(tmp, field) = (head)->sph_root;			\