virfdstream: Check for thread error more frequently
virfdstream: Check for thread error more frequently

When the I/O thread quits (e.g. due to an I/O error, lseek()
error, whatever), any subsequent virFDStream API should return
error too. Moreover, when invoking stream event callback, we must
set the VIR_STREAM_EVENT_ERROR flag so that the callback knows
something bad happened.

Signed-off-by: Michal Privoznik <83d82aaba2eed257f4814b0c239c260c4caaadf0@redhat.com>
Reviewed-by: John Ferlan <87558058f6f829e5ec976c8ef960720af4ff9c7d@redhat.com>

crobinso/libvirt,eskultety/libvirt,crobinso/libvirt,nertpinx/libvirt,nertpinx/libvirt,jfehlig/libvirt,jfehlig/libvirt,nertpinx/libvirt,eskultety/libvirt,libvirt/libvirt,jardasgit/libvirt,jardasgit/libvirt,eskultety/libvirt,fabianfreyer/libvirt,fabianfreyer/libvirt,nertpinx/libvirt,olafhering/libvirt,andreabolognani/libvirt,jfehlig/libvirt,zippy2/libvirt,datto/libvirt,olafhering/libvirt,datto/libvirt,libvirt/libvirt,olafhering/libvirt,libvirt/libvirt,datto/libvirt,zippy2/libvirt,nertpinx/libvirt,olafhering/libvirt,eskultety/libvirt,fabianfreyer/libvirt,andreabolognani/libvirt,andreabolognani/libvirt,jfehlig/libvirt,jardasgit/libvirt,datto/libvirt,andreabolognani/libvirt,fabianfreyer/libvirt,fabianfreyer/libvirt,jardasgit/libvirt,libvirt/libvirt,datto/libvirt,eskultety/libvirt,jardasgit/libvirt,zippy2/libvirt,crobinso/libvirt,zippy2/libvirt,andreabolognani/libvirt,crobinso/libvirt