[or-cvs] Unbork windows whitespace

Nick Mathewson nickm at seul.org
Sat Jun 5 01:56:57 UTC 2004


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

Modified Files:
	cpuworker.c or.h router.c 
Log Message:
Unbork windows whitespace

Index: cpuworker.c
===================================================================
RCS file: /home/or/cvsroot/src/or/cpuworker.c,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -d -r1.43 -r1.44
--- cpuworker.c	5 Jun 2004 01:50:35 -0000	1.43
+++ cpuworker.c	5 Jun 2004 01:56:54 -0000	1.44
@@ -201,7 +201,7 @@
 #ifndef MS_WINDOWS
   connection_free_all(); /* so the child doesn't hold the parent's fd's open */
 #endif
-
+
   dup_onion_keys(&onion_key, &last_onion_key);
 
   for(;;) {

Index: or.h
===================================================================
RCS file: /home/or/cvsroot/src/or/or.h,v
retrieving revision 1.364
retrieving revision 1.365
diff -u -d -r1.364 -r1.365
--- or.h	5 Jun 2004 01:50:35 -0000	1.364
+++ or.h	5 Jun 2004 01:56:54 -0000	1.365
@@ -1278,7 +1278,7 @@
 crypto_pk_env_t *get_previous_onion_key(void);
 time_t get_onion_key_set_at(void);
 void set_identity_key(crypto_pk_env_t *k);
-crypto_pk_env_t *get_identity_key(void);
+crypto_pk_env_t *get_identity_key(void);
 void dup_onion_keys(crypto_pk_env_t **key, crypto_pk_env_t **last);
 int init_keys(void);
 crypto_pk_env_t *init_key_from_file(const char *fname);

Index: router.c
===================================================================
RCS file: /home/or/cvsroot/src/or/router.c,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -d -r1.46 -r1.47
--- router.c	5 Jun 2004 01:50:35 -0000	1.46
+++ router.c	5 Jun 2004 01:56:54 -0000	1.47
@@ -21,7 +21,7 @@
  *****/
 
 /** Private keys for this OR.  There is also an SSL key managed by tortls.c.
- */
+ */
 static tor_mutex_t *key_lock=NULL;
 static time_t onionkey_set_at=0; /* When was onionkey last changed? */
 static crypto_pk_env_t *onionkey=NULL;
@@ -31,10 +31,10 @@
 /** Replace the current onion key with <b>k</b>.  Does not affect lastonionkey;
  * to update onionkey correctly, call rotate_onion_key().
  */
-void set_onion_key(crypto_pk_env_t *k) {
+void set_onion_key(crypto_pk_env_t *k) {
   tor_mutex_acquire(key_lock);
   onionkey = k;
-  onionkey_set_at = time(NULL);
+  onionkey_set_at = time(NULL);
   tor_mutex_release(key_lock);
 }
 
@@ -43,7 +43,7 @@
 crypto_pk_env_t *get_onion_key(void) {
   tor_assert(onionkey);
   return onionkey;
-}
+}
 
 /** Return the onion key that was current before the most recent onion
  * key rotation.  If no rotation has been performed since this process
@@ -51,18 +51,18 @@
  */
 crypto_pk_env_t *get_previous_onion_key(void) {
   return lastonionkey;
-}
-
-void dup_onion_keys(crypto_pk_env_t **key, crypto_pk_env_t **last)
-{
-  tor_assert(key && last);
-  tor_mutex_acquire(key_lock);
-  *key = crypto_pk_dup_key(onionkey);
-  if (lastonionkey)
-	*last = crypto_pk_dup_key(lastonionkey);
-  else
-    *last = NULL;
-  tor_mutex_release(key_lock);
+}
+
+void dup_onion_keys(crypto_pk_env_t **key, crypto_pk_env_t **last)
+{
+  tor_assert(key && last);
+  tor_mutex_acquire(key_lock);
+  *key = crypto_pk_dup_key(onionkey);
+  if (lastonionkey)
+    *last = crypto_pk_dup_key(lastonionkey);
+  else
+    *last = NULL;
+  tor_mutex_release(key_lock);
 }
 
 /** Return the time when the onion key was last set.  This is either the time
@@ -110,13 +110,13 @@
   if (crypto_pk_write_private_key_to_filename(prkey, fname)) {
     log(LOG_ERR, "Couldn't write generated key to %s.", fname);
     goto error;
-  }
+  }
   tor_mutex_acquire(key_lock);
   if (lastonionkey)
     crypto_free_pk_env(lastonionkey);
   log_fn(LOG_INFO, "Rotating onion key");
   lastonionkey = onionkey;
-  set_onion_key(prkey);
+  set_onion_key(prkey);
   tor_mutex_release(key_lock);
   return;
  error:
@@ -185,9 +185,9 @@
   char *cp;
   const char *tmp, *mydesc;
   crypto_pk_env_t *prkey;
-
-  if (!key_lock)
-	key_lock = tor_mutex_new();
+
+  if (!key_lock)
+    key_lock = tor_mutex_new();
 
   /* OP's don't need keys.  Just initialize the TLS context.*/
   if (!options.ORPort) {



More information about the tor-commits mailing list