Commit 9268ed2e by Frederik Kriewitz Committed by Tomas Hlavacek

BIRD: Fix timeout in case ip/subnet is not in the routing table

Fixes exceptions like this:
ERROR: Exception occured while running a command:Traceback (most recent
call last):
  File "/var/www/html/ulg.py", line 498, in commandThreadBody
    session.getRouter().runAsyncCommand(session.getCommand(),session.getParameters(),FakeSessionFile(session))
  File "/var/www/html/ulgmodel.py", line 463, in runAsyncCommand
    return self.runRawCommand(c,outfile)
  File "/var/www/html/ulgbird.py", line 544, in runRawCommand
    l = sf.readline()
  File "/usr/lib/python2.7/socket.py", line 447, in readline
    data = self._sock.recv(self._rbufsize)
timeout: timed out

Signed-off-by: Tomas Hlavacek <tmshlvck@gmail.com>
parent 2df681bf
......@@ -514,6 +514,9 @@ class BirdRouterLocal(ulgmodel.LocalRouter,BirdRouter):
elif(code == 13):
# show status last line
return True
elif(code == 8001):
# network not in table end
return True
elif(code >= 9000):
# probably error
return True
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment