Embedded Network patches - eventfd & socket getters (#19632)
This commit is contained in:
parent
7d32425a57
commit
eae29e8eaf
2 changed files with 36 additions and 9 deletions
|
|
@ -1798,6 +1798,16 @@ proc isSsl*(socket: Socket): bool =
|
|||
proc getFd*(socket: Socket): SocketHandle = return socket.fd
|
||||
## Returns the socket's file descriptor
|
||||
|
||||
when defined(zephyr) or defined(nimNetSocketExtras): # Remove in future
|
||||
proc getDomain*(socket: Socket): Domain = return socket.domain
|
||||
## Returns the socket's domain
|
||||
|
||||
proc getType*(socket: Socket): SockType = return socket.sockType
|
||||
## Returns the socket's type
|
||||
|
||||
proc getProtocol*(socket: Socket): Protocol = return socket.protocol
|
||||
## Returns the socket's protocol
|
||||
|
||||
when defined(nimHasStyleChecks):
|
||||
{.push styleChecks: off.}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue