RESOLVED INVALID 26302
GDOM-Binding: errors when executing XPath
https://bugs.webkit.org/show_bug.cgi?id=26302
Summary GDOM-Binding: errors when executing XPath
Leon Winter
Reported 2009-06-10 15:54:31 PDT
Hi, during execution of XPath via GDOM Binding there is intersting output: (test:32645): GLib-GObject-CRITICAL **: g_param_spec_double: assertion `default_value >= minimum && default_value <= maximum' failed (test:32645): GLib-GObject-CRITICAL **: g_object_class_install_property: assertion `G_IS_PARAM_SPEC (pspec)' failed Investigation and fix would be nice. Sample code: GdomXPathResult *res; char* exp = "//*[@href or @src]"; GdomDocument *doc = get_dom_document(); GdomNodeList *els = gdom_document_get_elements_by_tag_name(doc, "body"); GdomNode *body = gdom_node_list_item(els, 0); GdomXPathNSResolver *resolver = gdom_document_create_ns_resolver(doc, body); GdomNode *node; GdomCSSStyleDeclaration *style; int i = 0; res = gdom_document_evaluate(doc, exp, body, resolver, 0, NULL); while(res && (node = gdom_x_path_result_iterate_next(res))) { g_object_get(node, "style", &style, NULL); gdom_css_style_declaration_set_css_property(style, "border", "1px dashed red", ""); gdom_css_style_declaration_set_css_property(style, "background", "yellow", ""); g_object_unref(style); g_object_unref(node); ++i; } g_object_unref(resolver); g_object_unref(body); g_object_unref(els); g_object_unref(doc); g_object_unref(res); g_warning("found elements: %d\n", i);
Attachments
Luke Kenneth Casson Leighton
Comment 1 2009-07-13 15:06:43 PDT
(In reply to comment #0) > Hi, > > during execution of XPath via GDOM Binding there is intersting output: > > (test:32645): GLib-GObject-CRITICAL **: g_param_spec_double: assertion > `default_value >= minimum && default_value <= maximum' failed > > (test:32645): GLib-GObject-CRITICAL **: > g_object_class_install_property: assertion `G_IS_PARAM_SPEC (pspec)' > failed > > Investigation and fix would be nice. yehh, it's one of something like 20,000 properties _somewhere_. tracking it down is going to be one of those lairy by-rote tasks. i'll see if i can find it but it's not a high priority item, but still important all the same. thanks for raising it.
Jan Alonzo
Comment 2 2009-07-14 04:04:54 PDT
WebKitGtk do not have an official DOM bindings yet in the WebKit tree.
Note You need to log in before you can comment on or make changes to this bug.