Permalink
Browse files

Fix undefined variable and code check.

  • Loading branch information...
lantz committed Oct 19, 2018
1 parent d072e53 commit b7a6b8137f7da33a99265cddce3846a3eb621dfc
Showing with 3 additions and 3 deletions.
  1. +3 −3 examples/cluster.py
View
@@ -855,10 +855,10 @@ def addController( self, *args, **kwargs ):
remoteIP = serverIPs[ 0 ]
# Route should contain 'dev <intfname>'
route = controller.cmd( 'ip route get', remoteIP,
'| egrep -o "dev\s[^[:space:]]+"' )
r'| egrep -o "dev\s[^[:space:]]+"' )
if not route:
raise Exception('addController: no route from', c0, 'to',
remoteIP )
raise Exception('addController: no route from', controller,
'to', remoteIP )
intf = route.split()[ 1 ].strip()
debug( 'adding', intf, 'to', controller )
Intf( intf, node=controller ).updateIP()

0 comments on commit b7a6b81

Please sign in to comment.