Revision 91261b27 mininet/node.py

View differences:

mininet/node.py
1055 1055
                args.extend( ['-i', intf.name] )
1056 1056
        for c in controllers:
1057 1057
            args.extend( ['-c', '%s:%d' % (c.IP(), c.port)] )
1058
        if self.listenPort:
1059
            args.extend( ['--listen', '127.0.0.1:%i' % self.listenPort] )
1058 1060

  
1059 1061
        with open( '/tmp/ivs.%s.log' % self.name, 'w' ) as logfile:
1060 1062
            with open( '/dev/null', 'w' ) as nullfile:
......
1080 1082

  
1081 1083
    def dpctl( self, *args ):
1082 1084
        "Run dpctl command"
1083
        return "dpctl not supported\n" or args or self # satisfy pylint
1085
        if not self.listenPort:
1086
            return "can't run dpctl without passive listening port"
1087
        return self.cmd( 'dpctl ' + ' '.join( args ) +
1088
                         ' tcp:127.0.0.1:%i' % self.listenPort )
1084 1089

  
1085 1090

  
1086 1091
class Controller( Node ):

Also available in: Unified diff