diff --git a/include/wx/socket.h b/include/wx/socket.h index 165aa97890..6107362658 100644 --- a/include/wx/socket.h +++ b/include/wx/socket.h @@ -160,6 +160,7 @@ public: wxSocketFlags GetFlags() const { return m_flags; } void SetFlags(wxSocketFlags flags); void SetTimeout(long seconds); + long GetTimeout() const { return m_timeout; } bool GetOption(int level, int optname, void *optval, int *optlen); bool SetOption(int level, int optname, const void *optval, int optlen); diff --git a/interface/wx/socket.h b/interface/wx/socket.h index 0a7d42ba8e..621df49adf 100644 --- a/interface/wx/socket.h +++ b/interface/wx/socket.h @@ -712,6 +712,13 @@ public: */ bool GetPeer(wxSockAddress& addr) const; + /** + Return the socket timeout in seconds. + + The timeout can be set using SetTimeout() and is 10 minutes by default. + */ + long GetTimeout() const; + /** Returns @true if the socket is connected. */