]> git.ipfire.org Git - people/ric9/pakfire.git/commitdiff
stripper: Only copy regular source files
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 10 Jan 2025 16:31:29 +0000 (16:31 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 10 Jan 2025 16:31:29 +0000 (16:31 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/pakfire/stripper.c

index b7b02d05f9a08dcd0720f4841e3afb37924743b9..14f6dd654539a1acd43b11e156e9b01d396acdf1 100644 (file)
@@ -282,6 +282,10 @@ static int pakfire_stripper_copy_sources(
                goto ERROR;
        }
 
+       // If the source is not a regular file, we will skip it
+       if (!S_ISREG(st.st_mode))
+               goto ERROR;
+
        // Add the buildroot
        r = pakfire_path_append(p, self->path, path);
        if (r < 0)