From: Michael Tremer Date: Fri, 17 Mar 2023 14:29:12 +0000 (+0000) Subject: FHS: Perform world writable check only for regular files X-Git-Tag: 0.9.29~265 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=15c1f85e9e607bd72920ee66859b91a8a058f7ef;p=pakfire.git FHS: Perform world writable check only for regular files Signed-off-by: Michael Tremer --- diff --git a/src/libpakfire/fhs.c b/src/libpakfire/fhs.c index 63aa802cf..6daf8258b 100644 --- a/src/libpakfire/fhs.c +++ b/src/libpakfire/fhs.c @@ -221,6 +221,15 @@ ERROR: static int pakfire_fhs_check_world_writable( struct pakfire* pakfire, struct pakfire_file* file) { + // Run this check only for regular files + switch (pakfire_file_get_type(file)) { + case S_IFREG: + break; + + default: + return 0; + } + // Fetch path const char* path = pakfire_file_get_path(file);