• Bug#1102512: run-parts - fails on non-existing directories

    From Bastian Blank@21:1/5 to All on Wed Apr 9 22:20:01 2025
    Package: debianutils
    Version: 5.21
    Severity: important
    X-Debbugs-Cc: waldi@debian.org

    run-parts tries to implement the UAPI Configuration Files Spec, but it
    fails on non-existing directories. This is a bit not helpful, as one of
    the reasons for this spec is to allow /etc to be empty.

    diff -urN debianutils-5.21.orig/run-parts.c debianutils-5.21/run-parts.c
    --- debianutils-5.21.orig/run-parts.c 2024-11-15 15:42:16.000000000 +0100
    +++ debianutils-5.21/run-parts.c 2025-04-09 22:04:44.163743807 +0200
    @@ -506,8 +506,7 @@
    for (int i = 0; dirnames[i] != NULL; i++) {
    DIR *dirfd = opendir(dirnames[i]);
    if (!dirfd) {
    - error("failed to opendir %s: %s", dirnames[i], strerror(errno));
    - exit(1);
    + continue;
    }
    struct dirent *dp;
    while ((dp = readdir(dirfd)) != NULL) {

    Bastian

    -- System Information:
    Debian Release: trixie/sid
    APT prefers testing
    APT policy: (700, 'testing'), (500, 'proposed-updates'), (500, 'unstable'), (500, 'stable'), (1, 'experimental')
    Architecture: amd64 (x86_64)

    Kernel: Linux 6.13-amd64 (SMP w/16 CPU threads; PREEMPT)
    Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8), LANGUAGE=en_US:en
    Shell: /bin/sh linked to /usr/bin/dash
    Init: systemd (via /run/systemd/system)
    LSM: AppArmor: enabled

    Versions of packages debianutils depends on:
    ii libc6 2.41-6

    debianutils
  • From Bastian Blank@21:1/5 to Ileana Dumitrescu on Thu Apr 10 20:00:02 2025
    On Thu, Apr 10, 2025 at 07:52:08PM +0300, Ileana Dumitrescu wrote:
    Thank you for your bug report! I have applied your patch in salsa [1]
    with an informational message to users. With the upcoming trixie
    release, I would need to request permission from the Release Team to
    upload debianutils to unstable now, so I plan to wait until after trixie
    is released to upload 5.22.

    Then I will do it, because we need that in Trixie for Linux.

    Bastian

    --
    Hailing frequencies open, Captain.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)