[Libguestfs] [PATCH libnbd] lib/errors.c: Fix assert fail in exit path in multi-threaded code

Richard W.M. Jones rjones at redhat.com
Wed Mar 8 20:57:09 UTC 2023


On Wed, Mar 08, 2023 at 08:29:41PM +0000, Richard W.M. Jones wrote:
> diff --git a/generator/states.c b/generator/states.c
> index fa0f8d716e..c0cf5a7f26 100644
> --- a/generator/states.c
> +++ b/generator/states.c
> @@ -191,8 +191,6 @@ STATE_MACHINE {
>    return 0;
>  
>   DEAD:
> -  /* The caller should have used set_error() before reaching here */
> -  assert (nbd_get_error ());

On reflection it could be better to leave the comment (but delete the
assertion).

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines.  Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.
http://libguestfs.org/virt-v2v


More information about the Libguestfs mailing list