Fine with me, I've changed it in both patches.

Ethan

On Fri, Mar 9, 2012 at 12:20, Ben Pfaff <b...@nicira.com> wrote:
> On Thu, Mar 08, 2012 at 03:53:23PM -0800, Ethan Jackson wrote:
>>      iface_ids = {}              # Map from xs-vif-uuid to iface-id
>>      vm_ids = {}                 # Map from xs-vm-uuid to vm-id
>>      seqno = idl.change_seqno    # Sequence number when we last processed 
>> the db
>> -    while True:
>> +    while not exiting:
>>          idl.run()
>> +        unixctl_server.run()
>>          if not force_run and seqno == idl.change_seqno:
>>              poller = ovs.poller.Poller()
>> +
>> +            unixctl_server.wait(poller)
>>              idl.wait(poller)
>> +
>> +            if exiting:
>> +                poller.immediate_wake()
>> +
>>              poller.block()
>>              continue
>
> I believe that your code is correct, but unixctl_server.run() is what
> is going to set "exiting", so I'd be inclined to write it as:
>
>    while True:
>        unixctl_server.run()
>        if exiting:
>            break
>
>        idl.run()
>        if not force_run and seqno == idl.change_seqno:
>            poller = ovs.poller.Poller()
>            unixctl_server.wait(poller)
>            idl.wait(poller)
>            poller.block()
>            continue
>
> Thanks,
>
> Ben.
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to