ping method almost there
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3827 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
1d61ebaca1
commit
9841339c74
@ -477,6 +477,14 @@ wxDialUpManagerImpl::CheckStatusInternal(void)
|
||||
// sys_error("cannot create socket for gw");
|
||||
return;
|
||||
}
|
||||
#if 0
|
||||
// PING method:
|
||||
|
||||
if(sendto(sockfd, "hello", strlen("hello"), /* flags */ 0, &serv_addr,
|
||||
sizeof(serv_addr)) == -1)
|
||||
return;
|
||||
#endif
|
||||
|
||||
if( connect(sockfd, (struct sockaddr *) &serv_addr, sizeof(serv_addr)) < 0)
|
||||
{
|
||||
//sys_error("cannot connect to server");
|
||||
@ -484,6 +492,7 @@ wxDialUpManagerImpl::CheckStatusInternal(void)
|
||||
}
|
||||
//connected!
|
||||
close(sockfd);
|
||||
m_IsOnline = TRUE;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user