Small bugfixes in linkset code
[olsrd.git] / lib / dot_draw / src / olsrd_dot_draw.c
index 4811be8..a2b1b1e 100644 (file)
@@ -159,7 +159,8 @@ ipc_print_neigh_link(const struct neighbor_entry *neighbor)
   const char *style;
   const char *adr = olsr_ip_to_string(&mainaddrstrbuf, &olsr_cnf->main_addr);
   struct link_entry* link;
-
+  struct lqtextbuffer lqbuffer;
+  
   if (neighbor->status == 0) { // non SYM
     style = "dashed";
   } else {   
@@ -173,7 +174,7 @@ ipc_print_neigh_link(const struct neighbor_entry *neighbor)
   ipc_send_fmt("\"%s\" -> \"%s\"[label=\"%s\", style=%s];\n",
                adr,
                olsr_ip_to_string(&strbuf, &neighbor->neighbor_main_addr),
-               get_linkcost_text(etx, OLSR_FALSE),
+               get_linkcost_text(etx, OLSR_FALSE, &lqbuffer),
                style);
   
   if (neighbor->is_mpr) {
@@ -337,11 +338,12 @@ static void
 ipc_print_tc_link(const struct tc_entry *entry, const struct tc_edge_entry *dst_entry)
 {
   struct ipaddr_str strbuf1, strbuf2;
-
+  struct lqtextbuffer lqbuffer;
+  
   ipc_send_fmt("\"%s\" -> \"%s\"[label=\"%s\"];\n",
                olsr_ip_to_string(&strbuf1, &entry->addr),
                olsr_ip_to_string(&strbuf2, &dst_entry->T_dest_addr),
-               get_linkcost_text(dst_entry->cost, OLSR_FALSE));
+               get_linkcost_text(dst_entry->cost, OLSR_FALSE, &lqbuffer));
 }