portablectl: quote the profile name in the validation error
With an empty profile we get: $ portablectl attach -p "" foo Unit profile name not valid: It's not clear what is the profile. Let's quote it so it's clear also for empty profile names. (cherry picked from commit 6c8b21d30db4f4d5a0cdce9f2dc6a99b9b47e7c7)
This commit is contained in:
committed by
Luca Boccassi
parent
92d54a0d3d
commit
0b1c0782bb
@@ -1590,7 +1590,7 @@ static int parse_argv(int argc, char *argv[], char ***remaining_args) {
|
||||
|
||||
if (!filename_is_valid(opts.arg))
|
||||
return log_error_errno(SYNTHETIC_ERRNO(EINVAL),
|
||||
"Unit profile name not valid: %s", opts.arg);
|
||||
"Profile name '%s' is not valid.", opts.arg);
|
||||
|
||||
arg_profile = opts.arg;
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user