diff options
author | Peter Rajnoha <prajnoha@redhat.com> | 2015-07-31 10:20:33 +0200 |
---|---|---|
committer | Peter Rajnoha <prajnoha@redhat.com> | 2015-07-31 10:25:36 +0200 |
commit | f54198eed62f915df6fdb7c09a186160b5bb3954 (patch) | |
tree | d948457c4bc1193e735daacae85cd41ac71cb6c6 | |
parent | 0dae377fbf1e0b3e1484984602cbaf73487efa47 (diff) | |
download | lvm2-f54198eed62f915df6fdb7c09a186160b5bb3954.tar.gz |
toolcontext: use refresh_filters in refresh_toolcontext
Use refresh_filters instead of destroy_filters and init_filters
in refresh_toolcontext fn which deals with cmd->initialized.filters
correctly on refresh.
-rw-r--r-- | lib/commands/toolcontext.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/commands/toolcontext.c b/lib/commands/toolcontext.c index c087820f9..f4c0c9507 100644 --- a/lib/commands/toolcontext.c +++ b/lib/commands/toolcontext.c @@ -2011,7 +2011,6 @@ int refresh_toolcontext(struct cmd_context *cmd) label_exit(); _destroy_segtypes(&cmd->segtypes); _destroy_formats(cmd, &cmd->formats); - _destroy_filters(cmd); if (!dev_cache_exit()) stack; @@ -2109,7 +2108,7 @@ int refresh_toolcontext(struct cmd_context *cmd) if (cmd->initialized.connections && !init_connections(cmd)) return_0; - if (cmd->initialized.filters && !init_filters(cmd, 0)) + if (!refresh_filters(cmd)) return_0; reset_lvm_errno(1); |