Signed-off-by: Fabiano FidĂȘncio <fidencio(a)redhat.com>
---
libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.c | 18 ++++++++++++++++++
libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.h | 4 ++++
libvirt-gconfig/libvirt-gconfig.sym | 2 ++
3 files changed, 24 insertions(+)
diff --git a/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.c
b/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.c
index 96bbd74..94068a8 100644
--- a/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.c
+++ b/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.c
@@ -137,3 +137,21 @@ void
gvir_config_domain_graphics_vnc_set_password(GVirConfigDomainGraphicsVnc *g
"passwd", password,
NULL);
}
+
+const gchar *gvir_config_domain_graphics_vnc_get_host(GVirConfigDomainGraphicsVnc
*graphics)
+{
+ g_return_val_if_fail(GVIR_CONFIG_IS_DOMAIN_GRAPHICS_VNC(graphics), NULL);
+
+ return gvir_config_object_get_attribute(GVIR_CONFIG_OBJECT(graphics),
+ NULL, "listen");
+}
+
+void gvir_config_domain_graphics_vnc_set_host(GVirConfigDomainGraphicsVnc *graphics,
+ const gchar *host)
+{
+ g_return_if_fail(GVIR_CONFIG_IS_DOMAIN_GRAPHICS_VNC(graphics));
+
+ gvir_config_object_set_attribute_with_type(GVIR_CONFIG_OBJECT(graphics),
+ "listen", G_TYPE_STRING, host,
+ NULL);
+}
diff --git a/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.h
b/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.h
index 1d7afec..cad26ca 100644
--- a/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.h
+++ b/libvirt-gconfig/libvirt-gconfig-domain-graphics-vnc.h
@@ -77,6 +77,10 @@ void
gvir_config_domain_graphics_vnc_set_port(GVirConfigDomainGraphicsVnc *graph
void gvir_config_domain_graphics_vnc_set_password(GVirConfigDomainGraphicsVnc *graphics,
const char *password);
+const gchar *gvir_config_domain_graphics_vnc_get_host(GVirConfigDomainGraphicsVnc
*graphics);
+void gvir_config_domain_graphics_vnc_set_host(GVirConfigDomainGraphicsVnc *graphics,
+ const gchar *host);
+
G_END_DECLS
#endif /* __LIBVIRT_GCONFIG_DOMAIN_GRAPHICS_VNC_H__ */
diff --git a/libvirt-gconfig/libvirt-gconfig.sym b/libvirt-gconfig/libvirt-gconfig.sym
index bb72f33..44f0b09 100644
--- a/libvirt-gconfig/libvirt-gconfig.sym
+++ b/libvirt-gconfig/libvirt-gconfig.sym
@@ -743,6 +743,8 @@ LIBVIRT_GCONFIG_0.2.4 {
gvir_config_domain_graphics_spice_set_gl;
gvir_config_domain_graphics_spice_set_host;
gvir_config_domain_graphics_vnc_get_autoport;
+ gvir_config_domain_graphics_vnc_get_host;
+ gvir_config_domain_graphics_vnc_set_host;
gvir_config_domain_video_set_accel3d;
} LIBVIRT_GCONFIG_0.2.2;
--
2.5.0