[gxml] Removing warging in GomObject create instance
- From: Daniel Espinosa Ortiz <despinosa src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gxml] Removing warging in GomObject create instance
- Date: Thu, 2 Feb 2017 21:08:35 +0000 (UTC)
commit 533f4d874c7acd9c74fb6b0cdab9aa372e1166bf
Author: Daniel Espinosa <esodan gmail com>
Date: Thu Feb 2 15:07:36 2017 -0600
Removing warging in GomObject create instance
gxml/GomObject.vala | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/gxml/GomObject.vala b/gxml/GomObject.vala
index daba9f6..3ee3d1a 100644
--- a/gxml/GomObject.vala
+++ b/gxml/GomObject.vala
@@ -337,7 +337,10 @@ public interface GXml.GomObject : GLib.Object,
}
if (prop.value_type.is_a (typeof (GomElement))) {
obj = Object.new (prop.value_type);
- (obj as GomNode).set_parent (this);
+ try { (obj as GomNode).set_parent (this); }
+ catch (GLib.Error e) {
+ warning (_("Error while atemting to instantiate property object: %s").printf (e.message));
+ }
v.set_object (obj);
set_property (prop.name, v);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]