<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;">Hi,<br>I have changed many ways to fix the errors.<br>Firstly, if i place : wait_until_xrl_router_is_ready(...), it produces the errors: Assertion ..._cb==true failed.<br>Secondly, not using  wait_until_xrl_router_is_ready(...), i have called only _ospf.get_eventloop().run() and next the xrl command (_xrl_ospf_loopfree.send_notify_lsdb_change). The following errors occur: [xrl_router.cc send ] NO FINDER.<br>More than that, I have placed the code source not only in area_router.cc but also in xrl_io.cc and xrl_target.cc (in these cases, i want to use XrlRouter and EventLoop of the two classes). The result is: error NO FINDER.<br>I don't really understand why?<br>Thank you&nbsp; so much for explaining me<br>NGuyen Van
 Nam<br><br>///----------------------------------------------------------------------<br>try<br>&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp; //EventLoop eventloop;<br><br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; XrlStdRouter xrl_router(_ospf.get_eventloop(), "area_router");<br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //debug_msg("Waiting for router");<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; xrl_router.finalize();<br><br>&nbsp;&nbsp;&nbsp; XrlOspfLoopfreeV0p1Client xrl_ospf_loopfree_client(&amp;xrl_router);<br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; //cout&lt;&lt;"Test"&lt;&lt;endl;<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //wait_until_xrl_router_is_ready(_ospf.get_eventloop(), xrl_router);<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; //debug_msg("\n");<br>&nbsp;&nbsp;&nbsp; //event loop run<br>&nbsp;&nbsp;&nbsp; //cout&lt;&lt;"Test1"&lt;&lt;endl;<br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; bool
 success=false;<br>&nbsp;&nbsp;&nbsp; &nbsp;<br>&nbsp;&nbsp;&nbsp; while (!success)<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; {<br><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; _ospf.get_eventloop().run();&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;success=xrl_ospf_loopfree_client.send_reveive_lsdb_change("ospf_loopfree",<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; callback(this,&amp;AreaRouter::send_reveive_lsdb_change_cb ));<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br><br>&nbsp;&nbsp;&nbsp; //if (success) cout&lt;&lt; "LSDB change"&lt;&lt;endl;<br>&nbsp;&nbsp;&nbsp; //}<br>&nbsp;&nbsp;&nbsp; //success=false;<br>&nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; catch (...) {<br>&nbsp;&nbsp;&nbsp;
 xorp_catch_standard_exceptions(); }<br>//----------------------------------------------------------------------------------------------------------------------------------<br><br><div style="font-family: arial,helvetica,sans-serif; font-size: 13px;">----- Original Message ----<br>From: Bruce M Simpson &lt;bms@incunabulum.net&gt;<br>To: Nguyen Van Nam &lt;van_nam_78@yahoo.com&gt;<br>Cc: xorp-hackers &lt;xorp-hackers@icir.org&gt;<br>Sent: Tuesday, July 29, 2008 10:54:56 PM<br>Subject: Re: [Xorp-hackers] Problem with writing a xorp process<br><br>
Hi,<br><br>Please ignore my earlier comment about multiple callbacks, as it doesn't <br>apply here.<br><br>Nguyen Van Nam wrote:<br>&gt; Hi,<br>&gt; I use telnet localhost 19999 to verify xorp_finder. It is running. But <br>&gt; the error still occurs.<br>&gt; Note that: my source code is place at the module <a target="_blank" href="http://area_router.cc">area_router.cc</a>.<br>&gt; So what should I do now?<br><br>Based on the screenshot you've posted,and the data so far, it seems as <br>though the xorp_ospfv2 process is either not processing event callbacks <br>or is not returning from them.<br><br>Could you have introduced anything into the code which results in the <br>EventLoop not being called? This seems to be the most likely root cause <br>of the problem you're seeing.<br><br>thanks,<br>BMS<br></div></div></div><br>

      </body></html>