Loading...
Searching...
No Matches
util.h File Reference

sock utility function definitions More...

Detailed Description

sock utility function definitions

Author
Kaspar Schleiser kaspa.nosp@m.r@sc.nosp@m.hleis.nosp@m.er.d.nosp@m.e
Hauke Petersen hauke.nosp@m..pet.nosp@m.ersen.nosp@m.@fu-.nosp@m.berli.nosp@m.n.de

Definition in file util.h.

#include <stdbool.h>
#include <stdint.h>
#include "net/sock/config.h"
#include "net/sock/udp.h"
#include "net/sock/tcp.h"
+ Include dependency graph for util.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define SOCK_HAS_UDP   1
 UDP support is enabled.
 
#define SOCK_HAS_TCP   1
 TCP support is enabled.
 
#define HAVE_SOCK_TL_EP   1
 Indicates presence of struct _sock_tl_ep
 

Functions

int sock_urlsplit (const char *url, char *hostport, char *urlpath)
 Split url to host:port and url path.
 
const char * sock_urlpath (const char *url)
 Returns a pointer to the path component in url.
 
int sock_dtls_establish_session (sock_udp_t *sock_udp, sock_dtls_t *sock_dtls, sock_dtls_session_t *session, credman_tag_t tag, sock_udp_ep_t *local, const sock_udp_ep_t *remote, void *work_buf, size_t work_buf_len)
 Helper function to establish a DTLS connection.