On Tue, Sep 16, 2014 at 03:57:25PM +0200, Paolo Bonzini wrote: > Il 16/09/2014 15:53, Benoît Canet ha scritto: > >> static void iothread_complete(UserCreatable *obj, Error **errp) > >> > { > >> > + Error *local_error = NULL; > >> > IOThread *iothread = IOTHREAD(obj); > >> > > >> > iothread->stopping = false; > >> > - iothread->ctx = aio_context_new(); > >> > + iothread->ctx = aio_context_new(&local_error); > >> > + if (!iothread->ctx) { > >> > + error_report("%s", error_get_pretty(local_error)); > >> > + error_report("Failed to create AIO context"); > > I think reporting one line is sufficient. > > > > You could do something in the vein of. > > error_report("Failed to create AIO Context: \'%s\'", > > error_get_pretty(local_error)); > > > > > >> > + exit(1); > > Also here I don't know if exiting in the middle of a class initialization > > completion function is good taste. > > You should ask to someone knowing QOM. > > > > Indeed, the right thing to do is simply > > error_propagate(errp, local_error); > return; Just to note that after propagating the error and returning, QEMU fails silently without printing the error message.
I will make the proposed changes and try to resolve this in the next patch series if this is possible. Regards, Chrysostomos.