* [PATCH] hmp-cmd: fix a missing_break warning
@ 2020-03-18 7:16 Pan Nengyuan
2020-03-18 7:22 ` Pan Nengyuan
` (3 more replies)
0 siblings, 4 replies; 7+ messages in thread
From: Pan Nengyuan @ 2020-03-18 7:16 UTC (permalink / raw)
To: dgilbert; +Cc: zhukeqian1, zhanghailiang, Pan Nengyuan, qemu-devel, euler.robot
This fix coverity issues 94417686:
1260 break;
CID 94417686: (MISSING_BREAK)
1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
1262 p->has_throttle_trigger_threshold = true;
1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
Reported-by: Euler Robot <euler.robot@huawei.com>
Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
---
Cc: zhukeqian1@huawei.com
---
monitor/hmp-cmds.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
index 58724031ea..c882c9f3cc 100644
--- a/monitor/hmp-cmds.c
+++ b/monitor/hmp-cmds.c
@@ -1261,6 +1261,7 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
p->has_throttle_trigger_threshold = true;
visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
+ break;
case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
p->has_cpu_throttle_initial = true;
visit_type_int(v, param, &p->cpu_throttle_initial, &err);
--
2.21.0.windows.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] hmp-cmd: fix a missing_break warning
2020-03-18 7:16 [PATCH] hmp-cmd: fix a missing_break warning Pan Nengyuan
@ 2020-03-18 7:22 ` Pan Nengyuan
2020-03-18 8:10 ` zhukeqian
2020-03-24 17:40 ` Dr. David Alan Gilbert
2020-03-18 11:30 ` Dr. David Alan Gilbert
` (2 subsequent siblings)
3 siblings, 2 replies; 7+ messages in thread
From: Pan Nengyuan @ 2020-03-18 7:22 UTC (permalink / raw)
To: dgilbert; +Cc: euler.robot, zhukeqian1, qemu-devel, zhanghailiang
Correcting zhang hailiang's email.
On 3/18/2020 3:16 PM, Pan Nengyuan wrote:
> This fix coverity issues 94417686:
> 1260 break;
> CID 94417686: (MISSING_BREAK)
> 1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
> 1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> 1262 p->has_throttle_trigger_threshold = true;
> 1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> 1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
>
> Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
> Reported-by: Euler Robot <euler.robot@huawei.com>
> Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
> ---
> Cc: zhukeqian1@huawei.com
> ---
> monitor/hmp-cmds.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
> index 58724031ea..c882c9f3cc 100644
> --- a/monitor/hmp-cmds.c
> +++ b/monitor/hmp-cmds.c
> @@ -1261,6 +1261,7 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
> case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> p->has_throttle_trigger_threshold = true;
> visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> + break;
> case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
> p->has_cpu_throttle_initial = true;
> visit_type_int(v, param, &p->cpu_throttle_initial, &err);
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] hmp-cmd: fix a missing_break warning
2020-03-18 7:22 ` Pan Nengyuan
@ 2020-03-18 8:10 ` zhukeqian
2020-03-24 17:40 ` Dr. David Alan Gilbert
1 sibling, 0 replies; 7+ messages in thread
From: zhukeqian @ 2020-03-18 8:10 UTC (permalink / raw)
To: Pan Nengyuan, dgilbert; +Cc: wuchenye, euler.robot, qemu-devel, zhanghailiang
Hi Nengyuan,
On 2020/3/18 15:22, Pan Nengyuan wrote:
> Correcting zhang hailiang's email.
>
> On 3/18/2020 3:16 PM, Pan Nengyuan wrote:
>> This fix coverity issues 94417686:
>> 1260 break;
>> CID 94417686: (MISSING_BREAK)
>> 1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
>> 1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
>> 1262 p->has_throttle_trigger_threshold = true;
>> 1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
>> 1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
>>
>> Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
>> Reported-by: Euler Robot <euler.robot@huawei.com>
>> Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
>> ---
>> Cc: zhukeqian1@huawei.com
>> ---
>> monitor/hmp-cmds.c | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
>> index 58724031ea..c882c9f3cc 100644
>> --- a/monitor/hmp-cmds.c
>> +++ b/monitor/hmp-cmds.c
>> @@ -1261,6 +1261,7 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
>> case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
>> p->has_throttle_trigger_threshold = true;
>> visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
>> + break;
Good fix :).
>> case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
>> p->has_cpu_throttle_initial = true;
>> visit_type_int(v, param, &p->cpu_throttle_initial, &err);
>>
>
> .
>
Reviewed-by: Keqian Zhu <zhukeqian1@huawei.com>
Thanks,
Keqian
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] hmp-cmd: fix a missing_break warning
2020-03-18 7:16 [PATCH] hmp-cmd: fix a missing_break warning Pan Nengyuan
2020-03-18 7:22 ` Pan Nengyuan
@ 2020-03-18 11:30 ` Dr. David Alan Gilbert
2020-03-18 11:36 ` Philippe Mathieu-Daudé
2020-03-20 15:59 ` Peter Maydell
3 siblings, 0 replies; 7+ messages in thread
From: Dr. David Alan Gilbert @ 2020-03-18 11:30 UTC (permalink / raw)
To: Pan Nengyuan; +Cc: zhanghailiang, zhukeqian1, qemu-devel, euler.robot
* Pan Nengyuan (pannengyuan@huawei.com) wrote:
> This fix coverity issues 94417686:
> 1260 break;
> CID 94417686: (MISSING_BREAK)
> 1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
> 1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> 1262 p->has_throttle_trigger_threshold = true;
> 1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> 1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
>
> Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
> Reported-by: Euler Robot <euler.robot@huawei.com>
> Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
> ---
> Cc: zhukeqian1@huawei.com
> ---
> monitor/hmp-cmds.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
> index 58724031ea..c882c9f3cc 100644
> --- a/monitor/hmp-cmds.c
> +++ b/monitor/hmp-cmds.c
> @@ -1261,6 +1261,7 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
> case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> p->has_throttle_trigger_threshold = true;
> visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> + break;
Thanks!
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
> p->has_cpu_throttle_initial = true;
> visit_type_int(v, param, &p->cpu_throttle_initial, &err);
> --
> 2.21.0.windows.1
>
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] hmp-cmd: fix a missing_break warning
2020-03-18 7:16 [PATCH] hmp-cmd: fix a missing_break warning Pan Nengyuan
2020-03-18 7:22 ` Pan Nengyuan
2020-03-18 11:30 ` Dr. David Alan Gilbert
@ 2020-03-18 11:36 ` Philippe Mathieu-Daudé
2020-03-20 15:59 ` Peter Maydell
3 siblings, 0 replies; 7+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-03-18 11:36 UTC (permalink / raw)
To: Pan Nengyuan, dgilbert; +Cc: zhanghailiang, zhukeqian1, qemu-devel, euler.robot
On 3/18/20 8:16 AM, Pan Nengyuan wrote:
> This fix coverity issues 94417686:
> 1260 break;
> CID 94417686: (MISSING_BREAK)
> 1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
> 1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> 1262 p->has_throttle_trigger_threshold = true;
> 1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> 1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
>
> Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
> Reported-by: Euler Robot <euler.robot@huawei.com>
> Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
> ---
> Cc: zhukeqian1@huawei.com
> ---
> monitor/hmp-cmds.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
> index 58724031ea..c882c9f3cc 100644
> --- a/monitor/hmp-cmds.c
> +++ b/monitor/hmp-cmds.c
> @@ -1261,6 +1261,7 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
> case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> p->has_throttle_trigger_threshold = true;
> visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> + break;
> case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
> p->has_cpu_throttle_initial = true;
> visit_type_int(v, param, &p->cpu_throttle_initial, &err);
>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] hmp-cmd: fix a missing_break warning
2020-03-18 7:16 [PATCH] hmp-cmd: fix a missing_break warning Pan Nengyuan
` (2 preceding siblings ...)
2020-03-18 11:36 ` Philippe Mathieu-Daudé
@ 2020-03-20 15:59 ` Peter Maydell
3 siblings, 0 replies; 7+ messages in thread
From: Peter Maydell @ 2020-03-20 15:59 UTC (permalink / raw)
To: Pan Nengyuan
Cc: Euler Robot, zhanghailiang, Keqian Zhu, Dr. David Alan Gilbert,
QEMU Developers
On Wed, 18 Mar 2020 at 07:18, Pan Nengyuan <pannengyuan@huawei.com> wrote:
>
> This fix coverity issues 94417686:
> 1260 break;
> CID 94417686: (MISSING_BREAK)
> 1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
> 1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> 1262 p->has_throttle_trigger_threshold = true;
> 1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> 1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
This is CID 1421950. (I'm not sure where your number comes from.)
> Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
> Reported-by: Euler Robot <euler.robot@huawei.com>
> Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
thanks
-- PMM
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] hmp-cmd: fix a missing_break warning
2020-03-18 7:22 ` Pan Nengyuan
2020-03-18 8:10 ` zhukeqian
@ 2020-03-24 17:40 ` Dr. David Alan Gilbert
1 sibling, 0 replies; 7+ messages in thread
From: Dr. David Alan Gilbert @ 2020-03-24 17:40 UTC (permalink / raw)
To: Pan Nengyuan; +Cc: euler.robot, zhukeqian1, qemu-devel, zhanghailiang
* Pan Nengyuan (pannengyuan@huawei.com) wrote:
> Correcting zhang hailiang's email.
Queued
> On 3/18/2020 3:16 PM, Pan Nengyuan wrote:
> > This fix coverity issues 94417686:
> > 1260 break;
> > CID 94417686: (MISSING_BREAK)
> > 1261. unterminated_case: The case for value "MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD" is not terminated by a 'break' statement.
> > 1261 case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> > 1262 p->has_throttle_trigger_threshold = true;
> > 1263 visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> > 1264 case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
> >
> > Fixes: dc14a470763c96fd9d360e1028ce38e8c3613a77
> > Reported-by: Euler Robot <euler.robot@huawei.com>
> > Signed-off-by: Pan Nengyuan <pannengyuan@huawei.com>
> > ---
> > Cc: zhukeqian1@huawei.com
> > ---
> > monitor/hmp-cmds.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
> > index 58724031ea..c882c9f3cc 100644
> > --- a/monitor/hmp-cmds.c
> > +++ b/monitor/hmp-cmds.c
> > @@ -1261,6 +1261,7 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
> > case MIGRATION_PARAMETER_THROTTLE_TRIGGER_THRESHOLD:
> > p->has_throttle_trigger_threshold = true;
> > visit_type_int(v, param, &p->throttle_trigger_threshold, &err);
> > + break;
> > case MIGRATION_PARAMETER_CPU_THROTTLE_INITIAL:
> > p->has_cpu_throttle_initial = true;
> > visit_type_int(v, param, &p->cpu_throttle_initial, &err);
> >
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2020-03-24 17:41 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-18 7:16 [PATCH] hmp-cmd: fix a missing_break warning Pan Nengyuan
2020-03-18 7:22 ` Pan Nengyuan
2020-03-18 8:10 ` zhukeqian
2020-03-24 17:40 ` Dr. David Alan Gilbert
2020-03-18 11:30 ` Dr. David Alan Gilbert
2020-03-18 11:36 ` Philippe Mathieu-Daudé
2020-03-20 15:59 ` Peter Maydell
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.