Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Handle network change
11-09-2015, 03:16 PM
Post: #21
RE: Handle network change
(01-09-2015 08:13 AM)SiMet Wrote:  EDIT:
I found that in some cases (most of cases) DviProtocolUpnp::AddInterface is called before DviServer::AddServer and this cause that port in NOTIFY messages is 0 ( in DviServer::Port(TIpAddress aInterface) iServers.size() == 0 and 0 is returned )

Do you mean that following a call to Library::RefreshNetworkAdapterList(), DviProtocolUpnp::HandleInterfaceChange() is called before DviServer::SubnetListChanged()?

This would explain the issues you're seeing but I can't see why it'd happen.
Find all posts by this user
14-09-2015, 08:15 AM
Post: #22
RE: Handle network change
Yes, you're right. HandleInterfaceChange() is called before SubnetListChanged(). I do not know why it'd happen.
Find all posts by this user
28-09-2015, 02:12 PM
Post: #23
RE: Handle network change
(14-09-2015 08:15 AM)SiMet Wrote:  Yes, you're right. HandleInterfaceChange() is called before SubnetListChanged(). I do not know why it'd happen.

I've pushed some changes that should help ensure callbacks are run in the order they were registered in. Can you try the latest ohNet code to see if it fixes your issues please?
Find all posts by this user


Forum Jump: