mirror of
https://github.com/glest/glest-source.git
synced 2025-08-21 15:41:24 +02:00
- added some network debug output when network debug enabled for NIC's examined on network hosting (for Issue #137)
This commit is contained in:
@@ -738,6 +738,9 @@ std::vector<std::string> Socket::getLocalIPAddressList() {
|
|||||||
/* I want IP address attached to "eth0" */
|
/* I want IP address attached to "eth0" */
|
||||||
char szBuf[100]="";
|
char szBuf[100]="";
|
||||||
snprintf(szBuf,100,"%s%d",intfName.c_str(),idx);
|
snprintf(szBuf,100,"%s%d",intfName.c_str(),idx);
|
||||||
|
if(SystemFlags::getSystemSettingType(SystemFlags::debugNetwork).enabled) SystemFlags::OutputDebug(SystemFlags::debugNetwork,"In [%s::%s Line: %d] Trying NIC named [%s]\n",__FILE__,__FUNCTION__,__LINE__,szBuf);
|
||||||
|
//printf("In [%s::%s Line: %d] Trying NIC named [%s]\n",__FILE__,__FUNCTION__,__LINE__,szBuf);
|
||||||
|
|
||||||
int maxIfNameLength = std::min((int)strlen(szBuf),IFNAMSIZ-1);
|
int maxIfNameLength = std::min((int)strlen(szBuf),IFNAMSIZ-1);
|
||||||
|
|
||||||
strncpy(ifr.ifr_name, szBuf, maxIfNameLength);
|
strncpy(ifr.ifr_name, szBuf, maxIfNameLength);
|
||||||
|
Reference in New Issue
Block a user