14 #include <netinet/in.h>
15 #include <sys/types.h>
int create_domain_client(const char *path)
Create a unix domain client socket.
Definition: sockctl.c:108
int writeread_domain_data_str(char *socket_path, const char *write_str, char **reply)
Write and read a domain data string.
Definition: sockctl.c:396
ssize_t write_domain_data_s(int sock, const char *data, size_t data_len, const char *addr)
Write data to the domain server socket with a string address.
Definition: sockctl.c:321
ssize_t write_socket_data(int sock, const char *data, size_t data_len, const struct client_address *addr)
Write data to the server socket.
Definition: sockctl.c:373
int create_domain_server(const char *server_path)
Create a domain server object.
Definition: sockctl.c:150
ssize_t read_socket_data(int sock, char *data, size_t data_len, struct client_address *addr, int flags)
Read data from the server socket.
Definition: sockctl.c:279
SOCKET_TYPE
Definition: sockctl.h:18
@ SOCKET_TYPE_DOMAIN
Definition: sockctl.h:20
@ SOCKET_TYPE_NONE
Definition: sockctl.h:19
@ SOCKET_TYPE_UDP
Definition: sockctl.h:21
int create_udp_server(unsigned int port)
Create a udp server object.
Definition: sockctl.c:214
int close_domain_socket(int unix_domain_socket_fd)
Closes and cleans up a unix domain socket.
Definition: sockctl.c:186
ssize_t read_domain_data_s(int sock, char *data, size_t data_len, char *addr, int flags)
Read data from the domain server socket with a string address.
Definition: sockctl.c:302
Client address structure definition.
Definition: sockctl.h:28
struct sockaddr_un addr_un
Definition: sockctl.h:30
union client_address::@8 caddr
struct sockaddr_in addr_in
Definition: sockctl.h:31
enum SOCKET_TYPE type
Definition: sockctl.h:34
int len
Definition: sockctl.h:33