qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] iothread: Set the GSource "name" field


From: Peter Xu
Subject: Re: [PATCH] iothread: Set the GSource "name" field
Date: Tue, 5 Sep 2023 11:45:14 -0400

On Mon, Sep 04, 2023 at 11:48:11AM -0300, Fabiano Rosas wrote:
> @@ -189,11 +193,14 @@ static void iothread_init(EventLoopBase *base, Error 
> **errp)
>          return;
>      }
>  
> +    thread_name = g_strdup_printf("IO %s",
> +                        object_get_canonical_path_component(OBJECT(base)));
> +
>      /*
>       * Init one GMainContext for the iothread unconditionally, even if
>       * it's not used
>       */
> -    iothread_init_gcontext(iothread);
> +    iothread_init_gcontext(iothread, thread_name);
>  
>      iothread_set_aio_context_params(base, &local_error);
>      if (local_error) {

I think thread_name might be leaked if error here.  Thanks,

-- 
Peter Xu




reply via email to

[Prev in Thread] Current Thread [Next in Thread]