On Wed, Feb 05, 2020 at 05:18:55PM +0000, Daniel P. Berrangé wrote:
The libvirt-glib project has provided a GMainContext based
event loop impl for applications. This imports it and sets
it up for use by libvirt as the primary event loop. This
remains a private impl detail of libvirt.
IOW, applications must *NOT* assume that a call to
"virEventRegisterDefaultImpl" results in a GLib based
event loop. They should continue to use the libvirt-glib
API gvir_event_register() if they explicitly want to
guarantee a GLib event loop.
This follows the general principle that the libvirt public
API should not expose the fact that GLib is being used
internally.
Signed-off-by: Daniel P. Berrangé <berrange(a)redhat.com>
---
build-aux/syntax-check.mk | 2 +-
src/libvirt_private.syms | 5 +
src/libvirt_probes.d | 14 ++
src/util/Makefile.inc.am | 2 +
src/util/vireventglib.c | 499 ++++++++++++++++++++++++++++++++++++++
src/util/vireventglib.h | 28 +++
6 files changed, 549 insertions(+), 1 deletion(-)
create mode 100644 src/util/vireventglib.c
create mode 100644 src/util/vireventglib.h
Reviewed-by: Pavel Hrdina <phrdina(a)redhat.com>