Browse Source

Clear ifname buffer before copying into it.

pull/4/head
Adam Ierymenko 8 months ago
parent
commit
2f2f864aa8
No known key found for this signature in database
GPG Key ID: C8877CF2D7A5D7F3
  1. 1
      osdep/Binder.hpp

1
osdep/Binder.hpp

@ -465,6 +465,7 @@ class Binder {
if (_bindingCount < ZT_BINDER_MAX_BINDINGS) {
_bindings[_bindingCount].udpSock = udps;
_bindings[_bindingCount].address = ii->first;
memset(_bindings[_bindingCount].ifname, 0x0, sizeof(_bindings[_bindingCount].ifname));
memcpy(_bindings[_bindingCount].ifname, (char*)ii->second.c_str(), (int)ii->second.length());
++_bindingCount;
}

Loading…
Cancel
Save