Closed Bug 461166 Opened 11 years ago Closed 11 years ago

e4x parser borks on surrounding white spaces and certain response elements

Categories

(Calendar :: Provider: CalDAV, defect)

defect
Not set

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: Fallen, Assigned: Fallen)

Details

Attachments

(1 file, 1 obsolete file)

Attached patch Fix - v1 (obsolete) β€” β€” Splinter Review
Reproducable with SOGo, if the xml response contains trailing \r\n's, then the parser says syntax error. Also I've noticed that when going through a <multistatus><D:response>...</..></..> construct, using multistatus.*.length() is not 1 but 3, multistatus.*[0] and [2] being "\n", multistatus.*[1] being the actual <D:response>.

This patch should take care. I'm not 100% sure that the <D:response> element is always in the DAV namespace, so my iteration of |multistatus.D::response| instead of the old |multistatus.*....| may not work out. Please test/comment on this for review.
Attachment #344291 - Flags: review?(browning)
See section 11.2 of draft-desruisseaux-caldav-sched-05 - the response element should be in the CalDAV namespace.  This is not a change since -04 either - it was the same there.
Attached patch Fix - v2 β€” β€” Splinter Review
This patch is the same as the first, but uses *::response instead to take response elements from all namespaces into account.
Attachment #344291 - Attachment is obsolete: true
Attachment #345256 - Flags: review?(daniel.boelzle)
Attachment #344291 - Flags: review?(browning)
Comment on attachment 345256 [details] [diff] [review]
Fix - v2

r=dbo
Attachment #345256 - Flags: review?(daniel.boelzle) → review+
Pushed to comm-central <http://hg.mozilla.org/comm-central/rev/67040cc96e52>

-> FIXED
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.0
These bugs are likely targeted at Lightning 1.0b1, not Lightning 1.0. If this change was done in error, please adjust the target milestone to its correct value. To filter on this bugspam, you can use "lightning-10-target-move".
Target Milestone: 1.0 → 1.0b1
You need to log in before you can comment on or make changes to this bug.