Summary: | XmppReader treats nodes containing only whitespace as empty nodes. | ||
---|---|---|---|
Product: | Wocky | Reporter: | Will Thompson <will> |
Component: | General | Assignee: | Telepathy bugs list <telepathy-bugs> |
Status: | RESOLVED FIXED | QA Contact: | Telepathy bugs list <telepathy-bugs> |
Severity: | normal | ||
Priority: | medium | Keywords: | patch |
Version: | unspecified | ||
Hardware: | Other | ||
OS: | All | ||
URL: | http://git.collabora.co.uk/?p=user/wjt/wocky.git;a=commitdiff;h=refs/heads/whitespace-only-bodies | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
Will Thompson
2010-09-06 05:53:29 UTC
Here is a failing test case: http://git.collabora.co.uk/?p=user/wjt/wocky.git;a=commitdiff;h=refs/heads/whitespace-only-bodies I think that this might be caused by Wocky not implementing the ignorableWhitespace xmlSAXHandler vfunc. Well, the libxml2 documentation on this stuff is terrible. Even if I implement it, _ignorable_whitespace() is never called. Some searching threw up references to xmlKeepBlanksDefault(), but it appears to make no difference. I think we might be able to feed it a schema that mandates that all whitespace is significant, but I can't figure out how to do that right now. ARGAHAGHAGHAGHAGHAGH RGAHGHAGHGHR GRAGHAGHAGHR _end_element_ns: if (priv->node && priv->node->content) { /* Remove content if it's purely whitespace */ const char *c; for (c = priv->node->content; *c != '\0' && g_ascii_isspace (*c); c++) ; if (*c == '\0') wocky_node_set_content (priv->node, NULL); } RGHghghgh +" <message to='morse@met.police.uk' from='lewis@met.police.uk'> " \ I'm afraid Morse and Lewis were Oxfordshire police, and so weren't part of the Met. That should be thamesvalley.police.uk. Looks good otherwise. Merged with that heinous error corrected! |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.