1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-03-08 20:58:20 +03:00

Merge pull request #25314 from poettering/dissect-list-tweaks

dissect: minor tweaks to "systemd-dissect --list"
This commit is contained in:
Lennart Poettering 2022-11-09 14:42:30 +01:00 committed by GitHub
commit 00fa567d4a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -889,7 +889,6 @@ static int action_list_or_copy(DissectedImage *m, LoopDevice *d) {
} else {
_cleanup_close_ int dfd = -1;
_cleanup_strv_free_ char **list_dir = NULL;
assert(arg_action == ACTION_LIST);
@ -897,7 +896,9 @@ static int action_list_or_copy(DissectedImage *m, LoopDevice *d) {
if (dfd < 0)
return log_error_errno(errno, "Failed to open mount directory: %m");
r = recurse_dir(dfd, NULL, 0, UINT_MAX, RECURSE_DIR_SORT|RECURSE_DIR_ENSURE_TYPE|RECURSE_DIR_SAME_MOUNT, list_print_item, &list_dir);
pager_open(arg_pager_flags);
r = recurse_dir(dfd, NULL, 0, UINT_MAX, RECURSE_DIR_SORT, list_print_item, NULL);
if (r < 0)
return log_error_errno(r, "Failed to list image: %m");
}