mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-06 20:43:44 +02:00
Don't call _phy->getIfName if localSocket is -1
This commit is contained in:
parent
9797540212
commit
4e2439bd12
1 changed files with 3 additions and 1 deletions
|
@ -158,8 +158,10 @@ public:
|
||||||
{
|
{
|
||||||
memset(_ifname, 0, 16);
|
memset(_ifname, 0, 16);
|
||||||
memset(_addrString, 0, sizeof(_addrString));
|
memset(_addrString, 0, sizeof(_addrString));
|
||||||
|
if (_localSocket != -1) {
|
||||||
_phy->getIfName((PhySocket *) ((uintptr_t) _localSocket), _ifname, 16);
|
_phy->getIfName((PhySocket *) ((uintptr_t) _localSocket), _ifname, 16);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Called when a packet is received from this remote path, regardless of content
|
* Called when a packet is received from this remote path, regardless of content
|
||||||
|
|
Loading…
Add table
Reference in a new issue