[PATCH] security: Remove the superfluous break

Yi Wang posted 1 patch 3 years, 9 months ago
Test syntax-check failed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/1594951243-35113-1-git-send-email-wang.yi59@zte.com.cn
src/security/security_apparmor.c | 1 -
1 file changed, 1 deletion(-)
[PATCH] security: Remove the superfluous break
Posted by Yi Wang 3 years, 9 months ago
From: Liao Pingfang <liao.pingfang@zte.com.cn>

Remove the superfuous break, as there is a 'return' before it.

Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn>
Signed-off-by: Yi Wang <wang.yi59@zte.com.cn>
---
 src/security/security_apparmor.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/security/security_apparmor.c b/src/security/security_apparmor.c
index 3f6a213..eea37dc 100644
--- a/src/security/security_apparmor.c
+++ b/src/security/security_apparmor.c
@@ -699,7 +699,6 @@ AppArmorSetMemoryLabel(virSecurityManagerPtr mgr,
             return -1;
         }
         return reload_profile(mgr, def, mem->nvdimmPath, true);
-        break;
     case VIR_DOMAIN_MEMORY_MODEL_NONE:
     case VIR_DOMAIN_MEMORY_MODEL_DIMM:
     case VIR_DOMAIN_MEMORY_MODEL_LAST:
-- 
2.9.5

Re: [PATCH] security: Remove the superfluous break
Posted by Daniel Henrique Barboza 3 years, 9 months ago

On 7/16/20 11:00 PM, Yi Wang wrote:
> From: Liao Pingfang <liao.pingfang@zte.com.cn>
> 
> Remove the superfuous break, as there is a 'return' before it.
> 
> Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn>
> Signed-off-by: Yi Wang <wang.yi59@zte.com.cn>
> ---

Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>

>   src/security/security_apparmor.c | 1 -
>   1 file changed, 1 deletion(-)
> 
> diff --git a/src/security/security_apparmor.c b/src/security/security_apparmor.c
> index 3f6a213..eea37dc 100644
> --- a/src/security/security_apparmor.c
> +++ b/src/security/security_apparmor.c
> @@ -699,7 +699,6 @@ AppArmorSetMemoryLabel(virSecurityManagerPtr mgr,
>               return -1;
>           }
>           return reload_profile(mgr, def, mem->nvdimmPath, true);
> -        break;
>       case VIR_DOMAIN_MEMORY_MODEL_NONE:
>       case VIR_DOMAIN_MEMORY_MODEL_DIMM:
>       case VIR_DOMAIN_MEMORY_MODEL_LAST:
> 

Re: [PATCH] security: Remove the superfluous break
Posted by Ján Tomko 3 years, 9 months ago
On a Friday in 2020, Yi Wang wrote:
>From: Liao Pingfang <liao.pingfang@zte.com.cn>
>
>Remove the superfuous break, as there is a 'return' before it.
>
>Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn>
>Signed-off-by: Yi Wang <wang.yi59@zte.com.cn>
>---
> src/security/security_apparmor.c | 1 -
> 1 file changed, 1 deletion(-)
>

Reviewed-by: Ján Tomko <jtomko@redhat.com>
and pushed

Jano