From 1c33c715b926f82908ae75f19c35baf42da9e05b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Thomas=20Wei=C3=9Fschuh?= Date: Sun, 28 Apr 2024 23:23:47 +0200 Subject: [PATCH] lsfd: include buffer.h in decode-file-flags.h MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit buffer.h does not pull in the full c.h with it side-effects, so it can be used now. Drop the now unnecessary extern declarations. Signed-off-by: Thomas Weißschuh --- lsfd-cmd/decode-file-flags.c | 8 -------- lsfd-cmd/decode-file-flags.h | 2 +- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/lsfd-cmd/decode-file-flags.c b/lsfd-cmd/decode-file-flags.c index 7035d79d1..3f7ecd8f7 100644 --- a/lsfd-cmd/decode-file-flags.c +++ b/lsfd-cmd/decode-file-flags.c @@ -49,16 +49,8 @@ #error "kernel's fcntl.h is not available" #endif -#include /* for size_t */ - #include "decode-file-flags.h" -/* We cannot include buffer.h because buffer.h includes - * /usr/include/fcntl.h indirectly. */ -extern int ul_buffer_is_empty(struct ul_buffer *buf); -extern int ul_buffer_append_data(struct ul_buffer *buf, const char *data, size_t sz); -extern int ul_buffer_append_string(struct ul_buffer *buf, const char *str); - void lsfd_decode_file_flags(struct ul_buffer *buf, int flags) { #define SET_FLAG_FULL(L,s) \ diff --git a/lsfd-cmd/decode-file-flags.h b/lsfd-cmd/decode-file-flags.h index 88cd0d0be..5c045fd5a 100644 --- a/lsfd-cmd/decode-file-flags.h +++ b/lsfd-cmd/decode-file-flags.h @@ -1,7 +1,7 @@ #ifndef UTIL_LINUX_LSFD_DECODE_FILE_FLAGS_H #define UTIL_LINUX_LSFD_DECODE_FILE_FLAGS_H -struct ul_buffer; +#include "buffer.h" void lsfd_decode_file_flags(struct ul_buffer *buf, int flags); -- 2.47.3