From 461345a1640043f8b138f4707097685568cd6376 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 13 Apr 2022 22:51:13 +0200 Subject: [PATCH] execute: simplify 'load_creds_args' struct a bit Given we only need a single field off the ExecLoadCredential structure we don't have to link it as a whole, but just copy that one bit over directly, simplifying the struct a bit. --- src/core/execute.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/execute.c b/src/core/execute.c index eb06215266..de6ea28366 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -2701,7 +2701,7 @@ struct load_cred_args { Set *seen_creds; const ExecContext *context; const ExecParameters *params; - ExecLoadCredential *parent_load_credential; + bool encrypted; const char *unit; int dfd; uid_t uid; @@ -2749,7 +2749,7 @@ static int load_cred_recurse_dir_cb( args->params, sub_id, de->d_name, - args->parent_load_credential->encrypted, + args->encrypted, args->unit, dir_fd, args->dfd, @@ -2837,7 +2837,7 @@ static int acquire_credentials( .seen_creds = seen_creds, .context = context, .params = params, - .parent_load_credential = lc, + .encrypted = lc->encrypted, .unit = unit, .dfd = dfd, .uid = uid, -- 2.25.1