[or-cvs] Set handshake_state to NULL before appending cpath hops

Nick Mathewson nickm at seul.org
Tue Apr 6 20:24:00 UTC 2004


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

Modified Files:
	rendclient.c rendservice.c 
Log Message:
Set handshake_state to NULL before appending cpath hops

Index: rendclient.c
===================================================================
RCS file: /home/or/cvsroot/src/or/rendclient.c,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- rendclient.c	6 Apr 2004 03:44:36 -0000	1.20
+++ rendclient.c	6 Apr 2004 20:23:58 -0000	1.21
@@ -204,6 +204,9 @@
     goto err;
   }
 
+  crypto_dh_free(hop->handshake_state);
+  hop->handshake_state = NULL;
+
   /* All is well. Extend the circuit. */
   circ->purpose = CIRCUIT_PURPOSE_C_REND_JOINED;
   hop->state = CPATH_STATE_OPEN;

Index: rendservice.c
===================================================================
RCS file: /home/or/cvsroot/src/or/rendservice.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- rendservice.c	6 Apr 2004 03:44:36 -0000	1.31
+++ rendservice.c	6 Apr 2004 20:23:58 -0000	1.32
@@ -588,6 +588,9 @@
     goto err;
   }
 
+  crypto_dh_free(hop->handshake_state);
+  hop->handshake_state = NULL;
+
   /* Append the cpath entry. */
   hop->state = CPATH_STATE_OPEN;
   onion_append_to_cpath(&circuit->cpath, hop);



More information about the tor-commits mailing list