瀏覽代碼

Merge remote branch 'origin/maint-0.2.2'

Nick Mathewson 15 年之前
父節點
當前提交
d5907e7d9d
共有 3 個文件被更改,包括 12 次插入6 次删除
  1. 5 0
      changes/bug2629
  2. 5 5
      doc/HACKING
  3. 2 1
      src/or/circuitbuild.c

+ 5 - 0
changes/bug2629

@@ -0,0 +1,5 @@
+  o Minor bugfixes
+    - Fix a crash bug that could occur occasionally when a client was
+      configured with a large number of bridges.  Fixes bug 2629; bugfix
+      on 0.2.1.2-alpha.  Bugfix by trac user "shitlei".
+

+ 5 - 5
doc/HACKING

@@ -312,11 +312,11 @@ operation.
 If a library function is currently called such that failure always means ERR,
 If a library function is currently called such that failure always means ERR,
 then the library function should log WARN and let the caller log ERR.
 then the library function should log WARN and let the caller log ERR.
 
 
-[XXX Proposed convention: every message of severity INFO or higher should
-either (A) be intelligible to end-users who don't know the Tor source; or (B)
-somehow inform the end-users that they aren't expected to understand the
-message (perhaps with a string like "internal error").  Option (A) is to be
-preferred to option (B). -NM]
+Every message of severity INFO or higher should either (A) be intelligible
+to end-users who don't know the Tor source; or (B) somehow inform the
+end-users that they aren't expected to understand the message (perhaps
+with a string like "internal error"). Option (A) is to be preferred to
+option (B).
 
 
 Doxygen
 Doxygen
 ~~~~~~~~
 ~~~~~~~~

+ 2 - 1
src/or/circuitbuild.c

@@ -4748,7 +4748,8 @@ any_pending_bridge_descriptor_fetches(void)
         conn->purpose == DIR_PURPOSE_FETCH_SERVERDESC &&
         conn->purpose == DIR_PURPOSE_FETCH_SERVERDESC &&
         TO_DIR_CONN(conn)->router_purpose == ROUTER_PURPOSE_BRIDGE &&
         TO_DIR_CONN(conn)->router_purpose == ROUTER_PURPOSE_BRIDGE &&
         !conn->marked_for_close &&
         !conn->marked_for_close &&
-        conn->linked && !conn->linked_conn->marked_for_close) {
+        conn->linked &&
+        conn->linked_conn && !conn->linked_conn->marked_for_close) {
       log_debug(LD_DIR, "found one: %s", conn->address);
       log_debug(LD_DIR, "found one: %s", conn->address);
       return 1;
       return 1;
     }
     }