ust: improve message parsing
[ust.git] / libustcomm / ustcomm.h
CommitLineData
f9e5ce61
PMF
1#ifndef USTCOMM_H
2#define USTCOMM_H
3
4#include <sys/types.h>
b02e31e5 5#include <sys/un.h>
f9e5ce61 6
d0b5f2b9 7struct ustcomm_app {
b0540e11 8 /* the "server" socket for serving the external requests */
d0b5f2b9
PMF
9 int fd;
10 char *socketpath;
11};
12
13struct ustcomm_ustd {
b0540e11 14 /* the "server" socket for serving the external requests */
d0b5f2b9
PMF
15 int fd;
16 char *socketpath;
17};
18
b02e31e5
PMF
19struct ustcomm_source {
20 struct sockaddr_un addr;
21};
22
d0b5f2b9
PMF
23int send_message(pid_t pid, const char *msg, char **reply);
24
b02e31e5
PMF
25int ustcomm_ustd_recv_message(struct ustcomm_ustd *ustd, char **msg, struct ustcomm_source *src);
26int ustcomm_app_recv_message(struct ustcomm_app *app, char **msg, struct ustcomm_source *src);
3847c3ba 27
d0b5f2b9
PMF
28int ustcomm_init_app(pid_t pid, struct ustcomm_app *handle);
29
30int ustcomm_init_ustd(struct ustcomm_ustd *handle);
f9e5ce61 31
b02e31e5
PMF
32int nth_token_is(char *str, char *token, int tok_no);
33
34char *nth_token(char *str, int tok_no);
35
f9e5ce61 36#endif /* USTCOMM_H */
This page took 0.024 seconds and 4 git commands to generate.