master - cleanup: simplier struct initilization
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=5095a6517da9b57b0d2540b961e9841ad02fa8cc Commit: 5095a6517da9b57b0d2540b961e9841ad02fa8cc Parent: 338b991e4072734a4c37573d1bb541ecadee93b8 Author: Zdenek Kabelac <[email protected]> AuthorDate: Wed Aug 13 14:20:10 2014 +0200 Committer: Zdenek Kabelac <[email protected]> CommitterDate: Fri Aug 15 15:06:44 2014 +0200
cleanup: simplier struct initilization
--- tools/lvconvert.c | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-)
tools/lvconvert.c +3 -4
@@ -348,9 +348,6 @@ static int _read_params(struct lvconvert_params *lp, struct cmd_context *cmd,int pagesize =lvm_getpagesize ();const char *type_str =arg_str_value (cmd, type_ARG,"" ); -memset (lp,0 ,sizeof (*lp)); - lp->target_attr = ~0 ; -if (!_check_conversion_type (cmd, type_str)) return_0;
@@ -3315,7 +3312,9 @@ static int _lvconvert_merge_single(struct cmd_context *cmd, struct logical_volumint lvconvert (struct cmd_context * cmd,int argc,char **argv) { -struct lvconvert_params lp; +struct lvconvert_params lp = { + .target_attr = ~0 , + };if (!_read_params (&lp, cmd, argc, argv)) { stack;