mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-22 01:11:42 +00:00
Fixes TCPAcceptor able to use an empty string (#172)
This commit is contained in:
committed by
Peter Johnson
parent
976ca80056
commit
9a0a1baa6b
@@ -90,7 +90,7 @@ int TCPAcceptor::start() {
|
||||
#else
|
||||
int res = inet_pton(PF_INET, m_address.c_str(), &(address.sin_addr));
|
||||
#endif
|
||||
if (res != 1) {
|
||||
if (res != 1 && !m_address.empty()) {
|
||||
WPI_ERROR(m_logger, "could not resolve " << m_address << " address");
|
||||
return -1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user