diff options
author | Omar Polo <op@omarpolo.com> | 2024-01-21 19:40:06 +0000 |
---|---|---|
committer | Omar Polo <op@omarpolo.com> | 2024-01-21 19:40:06 +0000 |
commit | 83a2644bfb1d8683faf024275a98600b0edc5063 (patch) | |
tree | ea0783914312c1cf661315acd15ef787ad24b85c /logger.c | |
parent | 4f3b85e6d72b0df0b6264baf711290af4661807d (diff) |
convert remaining code to the imsg getters
Now gmid doesn't touch anymore the internals of the imsg structs.
Diffstat (limited to 'logger.c')
-rw-r--r-- | logger.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -79,7 +79,7 @@ logger_shutdown(void) static int logger_dispatch_parent(int fd, struct privsep_proc *p, struct imsg *imsg) { - switch (imsg->hdr.type) { + switch (imsg_get_type(imsg)) { case IMSG_LOG_FACILITY: if (imsg_get_data(imsg, &facility, sizeof(facility)) == -1) fatal("corrupted IMSG_LOG_SYSLOG"); @@ -108,7 +108,7 @@ logger_dispatch_server(int fd, struct privsep_proc *p, struct imsg *imsg) size_t datalen = 0; struct ibuf ibuf; - switch (imsg->hdr.type) { + switch (imsg_get_type(imsg)) { case IMSG_LOG_REQUEST: if (imsg_get_ibuf(imsg, &ibuf) == -1 || (datalen = ibuf_size(&ibuf)) == 0) |