tools/xsplice: cleanup unnecessary "j = ARRAY_SIZE(action_options); "
PATCH 1/1 tools/xsplice: cleanup unnecessary "j = ARRAY_SIZE(action_options); "
Local variable "j" would be used only when "i == ARRAY_SIZE(main_options)" is true. Thus, it is not necessary to update "j" when "i == ARRAY_SIZE(main_options)" is false.
--- tools/misc/xen-xsplice.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
tools/misc/xen-xsplice.c +1 -2
@@ -435,8 +435,7 @@ int main(int argc, char *argv[]) "'xen-xsplice help'\n", argv[1]);return 1 ; } - }else - j =ARRAY_SIZE (action_options); + } xch =xc_interface_open (0 ,0 ,0 );if ( !xch )
Signature · 7 lines
1.9.1 _______________________________________________ Xen-devel mailing list [email protected] http://lists.xen.org/xen-devel
Quoted 5 lines · Dongli Zhang
Local variable "j" would be used only when "i ==
ARRAY_SIZE(main_options)" is true. Thus, it is not necessary to update "j" when "i ==ARRAY_SIZE(main_options)" is false.Signed-off-by Dongli Zhang <[email protected]>
Wei, it is up to you whether it should go in 4.7 or in 4.8. This is a cleanup so it has no effect on the code.
Quoted 21 lines
--- tools/misc/xen-xsplice.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)tools/misc/xen-xsplice.c +1
-2@@ -435,8 +435,7 @@ int main(int argc, char *argv[]) "'xen-xsplice help'\n", argv[1]);return 1 ; } - }else - j =ARRAY_SIZE (action_options); + } xch =xc_interface_open (0 ,0 ,0 );if ( !xch )Signature · 1 line
1.9.1
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Quoted 5 lines · Konrad Rzeszutek Wilk
Quoted 4 lines · Dongli Zhang
Local variable "j" would be used only when "i ==
ARRAY_SIZE(main_options)" is true. Thus, it is not necessary to update "j" when "i ==ARRAY_SIZE(main_options)" is false.
Quoted 7 lines
Quoted 1 line
Signed-off-by Dongli Zhang <[email protected]>Reviewed-by Konrad Rzeszutek Wilk <[email protected]>Wei, it is up to you whether it should go in 4.7 or in 4.8. This is a cleanup so it has no effect on the code.
This can wait.
You obviously have more important code churn then this. Do want to make your life harder.
Wei.
Quoted 16 lines
Quoted 16 lines
--- tools/misc/xen-xsplice.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)tools/misc/xen-xsplice.c +1
-2@@ -435,8 +435,7 @@ int main(int argc, char *argv[]) "'xen-xsplice help'\n", argv[1]);return 1 ; } - }else - j =ARRAY_SIZE (action_options); + }
Quoted 5 lines
Quoted 5 lines
tools/misc/xen-xsplice.c +0
-0xch =xc_interface_open (0 ,0 ,0 );if ( !xch )Signature · 1 line
1.9.1
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Quoted 14 lines · Dongli Zhang
Local variable "j" would be used only when "i ==
ARRAY_SIZE(main_options)" is true. Thus, it is not necessary to update "j" when "i ==ARRAY_SIZE(main_options)" is false.Signed-off-by Dongli Zhang <[email protected]>--- tools/misc/xen-xsplice.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)tools/misc/xen-xsplice.c +0
-0
tools/misc/xen-xsplice.c int main(int argc, char *argv[]) · line 439
Quoted 7 lines
tools/misc/xen-xsplice.c +1
-2@@ -435,8 +435,7 @@ int main(int argc, char *argv[]) "'xen-xsplice help'\n", argv[1]);return 1 ; } - }else - j =ARRAY_SIZE (action_options); + }
And of course since xsplice doesn't exist anymore, this patch won't apply.
Dongli, can you resubmit this patch and update the subject line accordingly?
You can of course keep Konrad's Review-by tag. I don't expect him to object.
Wei.
Quoted 5 lines
tools/misc/xen-xsplice.c +0
-0xch =xc_interface_open (0 ,0 ,0 );if ( !xch )Signature · 1 line
1.9.1
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel