Fix forwarding of edge updates.
authorGuus Sliepen <guus@tinc-vpn.org>
Sun, 28 Feb 2016 15:28:28 +0000 (16:28 +0100)
committerGuus Sliepen <guus@tinc-vpn.org>
Sun, 28 Feb 2016 15:31:31 +0000 (16:31 +0100)
Commit e4670fc accidentily prevented ADD_EDGE messages from propagating
in some cases.

src/protocol_edge.c

index 5553f436fd95e70e6fced3a2226a893e1d93dd60..a4aaa0c918adfbb3c28e5b0c1cac94cb1e353a3b 100644 (file)
@@ -153,8 +153,7 @@ bool add_edge_h(connection_t *c, const char *request) {
                                        avl_insert_node(edge_weight_tree, node);
                                }
 
-                               graph();
-                               return true;
+                               goto done;
                        }
                } else if(sockaddrcmp(&e->local_address, &local_address)) {
                        if(from == myself) {
@@ -212,6 +211,7 @@ bool add_edge_h(connection_t *c, const char *request) {
        e->weight = weight;
        edge_add(e);
 
+done:
        /* Tell the rest about the new edge */
 
        if(!tunnelserver)