Method

GioSocketget_fd

since: 2.22

Declaration [src]

int
g_socket_get_fd (
  GSocket* socket
)

Description [src]

Gets the underlying OS socket descriptor.

On Unix this is a socket file descriptor, and on Windows this is a Winsock2 SOCKET handle.

This may be useful for doing platform specific or otherwise unusual operations on the socket.

Available since: 2.22

Gets propertyGio.Socket:fd

Return value

Type: int

The file descriptor of the socket, or -1 if the socket has not yet been initialised or has been closed.