From: Philip Withnall Date: Tue, 2 Jun 2026 11:59:04 +0000 (+0100) Subject: sysupdate: Minor fix to a cleanup function on an error path X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6ff8027ee1f9d443bc14b5ac2e91ec30d52a2d69;p=thirdparty%2Fsystemd.git sysupdate: Minor fix to a cleanup function on an error path `process_image()` has historically used `umount_and_freep` to clean up the mounted directory locally, but callers to it have used `umount_and_rmdir_and_freep`. No directory is created after any of the error return paths in `process_image()`, so it should probably be using `umount_and_rmdir_and_freep` too. --- diff --git a/src/sysupdate/sysupdate.c b/src/sysupdate/sysupdate.c index 3232ab6e377..a4c68e48cfd 100644 --- a/src/sysupdate/sysupdate.c +++ b/src/sysupdate/sysupdate.c @@ -983,7 +983,7 @@ static int process_image( ProcessImageFlags flags) { _cleanup_(loop_device_unrefp) LoopDevice *loop_device = NULL; - _cleanup_(umount_and_freep) char *mounted_dir = NULL; + _cleanup_(umount_and_rmdir_and_freep) char *mounted_dir = NULL; int r; assert(c);