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

[or-cvs] bugfix on my friday commit: make hidden services work again...



Update of /home/or/cvsroot/src/or
In directory moria.mit.edu:/home2/arma/work/onion/cvs/src/or

Modified Files:
	directory.c 
Log Message:
bugfix on my friday commit: make hidden services work again in cvs


Index: directory.c
===================================================================
RCS file: /home/or/cvsroot/src/or/directory.c,v
retrieving revision 1.138
retrieving revision 1.139
diff -u -d -r1.138 -r1.139
--- directory.c	8 Oct 2004 05:53:59 -0000	1.138
+++ directory.c	12 Oct 2004 06:03:10 -0000	1.139
@@ -270,6 +270,13 @@
 
       httpcommand = "GET";
       sprintf(url, "%s/rendezvous/%s", use_newer ? "/tor" : "", payload);
+
+      /* XXX We're using payload here to mean something other than
+       * payload of the http post. This is probably bad, and should
+       * be fixed one day. Kludge for now to make sure we don't post more. */
+      payload_len = 0;
+      payload = NULL;
+
       break;
     case DIR_PURPOSE_UPLOAD_RENDDESC:
       tor_assert(payload);
@@ -286,7 +293,7 @@
            hoststring);
   connection_write_to_buf(tmp, strlen(tmp), conn);
 
-  if(purpose == DIR_PURPOSE_UPLOAD_DIR || purpose == DIR_PURPOSE_UPLOAD_RENDDESC) {
+  if(payload) {
     /* then send the payload afterwards too */
     connection_write_to_buf(payload, payload_len, conn);
   }