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

[or-cvs] r11143: Terminate multi-line controller events correctly with a sing (in tor/branches/tor-0_1_2-patches: . doc src/or)



Author: nickm
Date: 2007-08-16 14:32:45 -0400 (Thu, 16 Aug 2007)
New Revision: 11143

Modified:
   tor/branches/tor-0_1_2-patches/
   tor/branches/tor-0_1_2-patches/ChangeLog
   tor/branches/tor-0_1_2-patches/doc/TODO.012
   tor/branches/tor-0_1_2-patches/src/or/control.c
Log:
 r14610@catbus:  nickm | 2007-08-16 14:31:44 -0400
 Terminate multi-line controller events correctly with a single "650 OK".  Backport of 10964.



Property changes on: tor/branches/tor-0_1_2-patches
___________________________________________________________________
 svk:merge ticket from /tor/012 [r14610] on 8246c3cf-6607-4228-993b-4d95d33730f1

Modified: tor/branches/tor-0_1_2-patches/ChangeLog
===================================================================
--- tor/branches/tor-0_1_2-patches/ChangeLog	2007-08-16 17:46:30 UTC (rev 11142)
+++ tor/branches/tor-0_1_2-patches/ChangeLog	2007-08-16 18:32:45 UTC (rev 11143)
@@ -27,6 +27,7 @@
       where no controller could authenticate. Now we exit.
     - If we require CookieAuthentication, stop generating a new cookie
       every time we change any piece of our config.
+    - Terminate multi-line control events properly. (Original patch from tup.)
 
 
 Changes in version 0.1.2.16 - 2007-08-01

Modified: tor/branches/tor-0_1_2-patches/doc/TODO.012
===================================================================
--- tor/branches/tor-0_1_2-patches/doc/TODO.012	2007-08-16 17:46:30 UTC (rev 11142)
+++ tor/branches/tor-0_1_2-patches/doc/TODO.012	2007-08-16 18:32:45 UTC (rev 11143)
@@ -13,7 +13,7 @@
   - r10579: new addsysuser implementation for osx (??)
   - Some fix for bug 438 (??)
   - coderman's constrained socket buffers patch (r10843)
-  - r10964: control.c grammar conformance. could conceivably break
+  o r10964: control.c grammar conformance. could conceivably break
     old controllers that were relying on non-conformance.
 
 

Modified: tor/branches/tor-0_1_2-patches/src/or/control.c
===================================================================
--- tor/branches/tor-0_1_2-patches/src/or/control.c	2007-08-16 17:46:30 UTC (rev 11142)
+++ tor/branches/tor-0_1_2-patches/src/or/control.c	2007-08-16 18:32:45 UTC (rev 11143)
@@ -3181,6 +3181,8 @@
   strlcpy(buf+strlen(firstline), esc, totallen);
   send_control1_event_string(EVENT_AUTHDIR_NEWDESCS, ALL_NAMES|ALL_FORMATS,
                              buf);
+  send_control1_event_string(EVENT_AUTHDIR_NEWDESCS, ALL_NAMES|ALL_FORMATS,
+                             "650 OK\r\n");
 
   tor_free(esc);
   tor_free(buf);
@@ -3212,6 +3214,7 @@
   SMARTLIST_FOREACH(strs, char *, cp, tor_free(cp));
   smartlist_free(strs);
   send_control1_event_string(EVENT_NS, ALL_NAMES|ALL_FORMATS, s);
+  send_control1_event_string(EVENT_NS, ALL_NAMES|ALL_FORMATS, "650 OK\r\n");
   tor_free(s);
   return 0;
 }