diff options
author | Dimitri Staessens <[email protected]> | 2024-02-23 09:29:47 +0100 |
---|---|---|
committer | Sander Vrijders <[email protected]> | 2024-02-23 16:41:37 +0100 |
commit | e6c2d4c9c6b8b12bbcf7bc8bd494b3ba56133e1f (patch) | |
tree | ad959d95f8fb1f6d4744c57c9027bf182bc3190b /include/ouroboros/sockets.h.in | |
parent | dcefa07624926da23a559eedc3f7361ac36e8312 (diff) | |
download | ouroboros-e6c2d4c9c6b8b12bbcf7bc8bd494b3ba56133e1f.tar.gz ouroboros-e6c2d4c9c6b8b12bbcf7bc8bd494b3ba56133e1f.zip |
lib: Revise app flow allocation
This revises the application flow allocator to use the flow_info
struct/message between the components. Revises the messaging to move
the use protocol buffers to its own source (serdes-irm).
Adds a timeout to the IRMd flow allocator to make sure flow
allocations don't hang forever (this was previously taken care of by
the sanitize thread).
Signed-off-by: Dimitri Staessens <[email protected]>
Signed-off-by: Sander Vrijders <[email protected]>
Diffstat (limited to 'include/ouroboros/sockets.h.in')
-rw-r--r-- | include/ouroboros/sockets.h.in | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/include/ouroboros/sockets.h.in b/include/ouroboros/sockets.h.in index cd198781..095674a9 100644 --- a/include/ouroboros/sockets.h.in +++ b/include/ouroboros/sockets.h.in @@ -23,18 +23,17 @@ #ifndef OUROBOROS_LIB_SOCKETS_H #define OUROBOROS_LIB_SOCKETS_H -#include <sys/types.h> +#include <ouroboros/protobuf.h> -#include "irm.pb-c.h" -typedef IrmMsg irm_msg_t; +#include <sys/types.h> -#define SOCK_PATH "/var/run/ouroboros/" -#define SOCK_PATH_SUFFIX ".sock" +#define SOCK_PATH "/var/run/ouroboros/" +#define SOCK_PATH_SUFFIX ".sock" -#define IRM_SOCK_PATH SOCK_PATH "irm" SOCK_PATH_SUFFIX +#define IRM_SOCK_PATH SOCK_PATH "irm" SOCK_PATH_SUFFIX #define IPCP_SOCK_PATH_PREFIX SOCK_PATH "ipcp" -#define SOCK_BUF_SIZE @SOCK_BUF_SIZE@ +#define SOCK_BUF_SIZE @SOCK_BUF_SIZE@ /* Returns the full socket path of an IPCP */ char * ipcp_sock_path(pid_t pid); @@ -43,8 +42,9 @@ int server_socket_open(char * file_name); int client_socket_open(char * file_name); -irm_msg_t * send_recv_irm_msg(irm_msg_t * msg); +int send_recv_msg(buffer_t * buf); +irm_msg_t * send_recv_irm_msg(irm_msg_t * msg); /* cleanup socket when cancelling thread */ void __cleanup_close_ptr(void * o); |