From c59f6545575624f32f8baaa34d3d47bfd0fe845a Mon Sep 17 00:00:00 2001 From: zshuang0316 Date: Fri, 27 Mar 2026 14:50:42 +0800 Subject: [PATCH] input_thread: replace raw read() with pipe abstraction to fix crash Signed-off-by: zshuang0316 --- src/flb_input_thread.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/flb_input_thread.c b/src/flb_input_thread.c index 8604a407081..fe35993cce2 100644 --- a/src/flb_input_thread.c +++ b/src/flb_input_thread.c @@ -59,9 +59,9 @@ static inline int handle_input_event(flb_pipefd_t fd, struct flb_input_instance uint64_t val; struct flb_config *config = ins->config; - bytes = read(fd, &val, sizeof(val)); + bytes = flb_pipe_r(fd, &val, sizeof(val)); if (bytes == -1) { - flb_errno(); + flb_pipe_error(); return -1; }