On 08/03/2024 11.12, Zhao Liu wrote:
Hi Thomas,
void s390_realize_cpu_model(CPUState *cs, Error **errp)
{
+ERRP_GUARD();
Error *err = NULL;
I think that function could use an additional clean-up now: Remove the local
"err" variable and use "errp" only instead.
Since many c
Hi Thomas,
> > void s390_realize_cpu_model(CPUState *cs, Error **errp)
> > {
> > +ERRP_GUARD();
> > Error *err = NULL;
>
> I think that function could use an additional clean-up now: Remove the local
> "err" variable and use "errp" only instead.
>
Since many cases check @err to det
> > diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c
> > index a63d990e4e8e..1a1c09612271 100644
> > --- a/target/s390x/cpu_models.c
> > +++ b/target/s390x/cpu_models.c
> > @@ -503,6 +503,7 @@ static void error_prepend_missing_feat(const char
> > *name, void *opaque)
> > static
On 29/02/2024 15.39, Zhao Liu wrote:
From: Zhao Liu
As the comment in qapi/error, passing @errp to error_prepend() requires
ERRP_GUARD():
* = Why, when and how to use ERRP_GUARD() =
*
* Without ERRP_GUARD(), use of the @errp parameter is restricted:
...
* - It should not be passed to error_pre
From: Zhao Liu
As the comment in qapi/error, passing @errp to error_prepend() requires
ERRP_GUARD():
* = Why, when and how to use ERRP_GUARD() =
*
* Without ERRP_GUARD(), use of the @errp parameter is restricted:
...
* - It should not be passed to error_prepend(), error_vprepend() or
* error_a