1CURLOPT_ABSTRACT_UNIX_SOCKETc(u3r)l_easy_setopt optiCoUnRsLOPT_ABSTRACT_UNIX_SOCKET(3)
2
3
4

NAME

6       CURLOPT_ABSTRACT_UNIX_SOCKET - abstract Unix domain socket
7

SYNOPSIS

9       #include <curl/curl.h>
10
11       CURLcode curl_easy_setopt(CURL *handle, CURLOPT_ABSTRACT_UNIX_SOCKET,
12                                 char *path);
13

DESCRIPTION

15       Enables the use of an abstract Unix domain socket instead of establish‐
16       ing a TCP connection to a host. The parameter should be a char *  to  a
17       null-terminated string holding the path of the socket. The path will be
18       set to path prefixed by a NULL byte (this is  the  convention  for  ab‐
19       stract  sockets,  however it should be stressed that the path passed to
20       this function should not contain a leading NULL).
21
22       On non-supporting platforms, the abstract address will  be  interpreted
23       as an empty string and fail gracefully, generating a run-time error.
24
25       This option shares the same semantics as CURLOPT_UNIX_SOCKET_PATH(3) in
26       which documentation more details can be found.  Internally,  these  two
27       options  share  the  same storage and therefore only one of them can be
28       set per handle.
29

DEFAULT

31       Default is NULL.
32

PROTOCOLS

34       All
35

EXAMPLE

37         curl_easy_setopt(curl_handle, CURLOPT_ABSTRACT_UNIX_SOCKET, "/tmp/foo.sock");
38         curl_easy_setopt(curl_handle, CURLOPT_URL, "http://localhost/");
39
40

AVAILABILITY

42       Added in 7.53.0.
43

RETURN VALUE

45       Returns CURLE_OK if the option is supported,  and  CURLE_UNKNOWN_OPTION
46       if not.
47

SEE ALSO

49       CURLOPT_UNIX_SOCKET_PATH(3), unix(7),
50
51
52
53libcurl 7.82.0                 November 26, 2021CURLOPT_ABSTRACT_UNIX_SOCKET(3)
Impressum