1MONGOC_SOCKET_CLOSE(3) libmongoc MONGOC_SOCKET_CLOSE(3)
2
3
4
6 int
7 mongoc_socket_close (mongoc_socket_t *socket);
8
10 • socket: A mongoc_socket_t.
11
13 This function is a wrapper around the BSD socket shutdown() and close()
14 functions, and their Windows equivalents. The socket is shut down only
15 if the current process is the same as the process that opened the
16 socket. Regardless, the socket is then closed.
17
19 0 on success, -1 on failure to close the socket. On failure, the
20 socket's errno is set; retrieve it with mongoc_socket_errno().
21
23 MongoDB, Inc
24
26 2017-present, MongoDB, Inc
27
28
29
30
311.25.1 Nov 08, 2023 MONGOC_SOCKET_CLOSE(3)