diff options
author | Rafał Miłecki <rafal@milecki.pl> | 2022-08-16 12:08:51 +0200 |
---|---|---|
committer | Rafał Miłecki <rafal@milecki.pl> | 2022-08-28 13:05:10 +0200 |
commit | 5de3871898e1ef4aec773e4dc9dc18acf52acee4 (patch) | |
tree | 3f3934bfb78e87f42a2c0cfb42eddae5ad632e8a | |
parent | f84f49f00fb70364f58b4cce72f1796a7190d370 (diff) | |
download | uci-5de3871898e1ef4aec773e4dc9dc18acf52acee4.tar.gz |
cli: drop redundant uci_add_delta_path() call for -P
savedir is always present in the list of delta paths. It's guaranteed by
1. uci_alloc_context() which sets defaults
2. uci_set_savedir() which allows changing savedir
Calling uci_add_delta_path() with ctx->savedir argument seems to always
return UCI_ERR_DUPLICATE.
Fixes: 2b4872345ab2b ("make use of the history path feature in the cli")
Cc: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
-rw-r--r-- | cli.c | 1 |
1 files changed, 0 insertions, 1 deletions
@@ -748,7 +748,6 @@ int main(int argc, char **argv) uci_add_delta_path(ctx, optarg); break; case 'P': - uci_add_delta_path(ctx, ctx->savedir); uci_set_savedir(ctx, optarg); flags |= CLI_FLAG_NOCOMMIT; break; |