Validation chokes on empty xsd:date instance data

RESOLVED FIXED

Status

()

Core
Web Services
RESOLVED FIXED
11 years ago
11 years ago

People

(Reporter: Allan Beaufour, Assigned: Allan Beaufour)

Tracking

({fixed1.8.0.5, fixed1.8.1})

Trunk
fixed1.8.0.5, fixed1.8.1
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(2 attachments)

1.60 KB, application/xhtml+xml
Details
907 bytes, patch
Doron Rosenberg (IBM)
: review+
Details | Diff | Splinter Review
(Assignee)

Description

11 years ago
Something goes wrong in the validation of empty instance data with type "xsd:date". The following assertion appears:
###!!! ASSERTION: |First()| called on an empty string: 'mLength > 0', file ../../../dist/include/string/nsTSubstring.h, line 201
(Assignee)

Comment 1

11 years ago
Created attachment 211252 [details]
Testcase

On load I get:
nsXFormsModelElement::Rebuild()
nsXFormsModelElement::Recalculate()
nsXFormsModelElement::Revalidate()
###!!! ASSERTION: |First()| called on an empty string: 'mLength > 0', file ../../../dist/include/string/nsTSubstring.h, line 201
Break: at file ../../../dist/include/string/nsTSubstring.h, line 201
nsXFormsModelElement::InitializeControls()

And on clicking submit (wihout entering anything in the field):
nsXFormsModelElement::Recalculate()
nsXFormsModelElement::Revalidate()
###!!! ASSERTION: |First()| called on an empty string: 'mLength > 0', file ../../../dist/include/string/nsTSubstring.h, line 201
Break: at file ../../../dist/include/string/nsTSubstring.h, line 201
WARNING: NS_ENSURE_TRUE(principal) failed, file nsDocument.cpp, line 1279
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsXFormsSubmissionElement.cpp, line 1321
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsXFormsSubmissionElement.cpp, line 1179
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsXFormsSubmissionElement.cpp, line 862
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsXFormsSubmissionElement.cpp, line 652

Comment 2

11 years ago
sounds like debugging it, at least, should be straight forward.  Reassigning to Barry.
Assignee: doronr → barrya
(Assignee)

Updated

11 years ago
Blocks: 331209
(Assignee)

Updated

11 years ago
Assignee: barrya → allan
(Assignee)

Comment 3

11 years ago
Created attachment 222846 [details] [diff] [review]
Patch
Attachment #222846 - Flags: review?(doronr)
(Assignee)

Updated

11 years ago
Status: NEW → ASSIGNED
Component: XForms → Web Services

Updated

11 years ago
Attachment #222846 - Flags: review?(doronr) → review+
(Assignee)

Comment 4

11 years ago
Fixed on trunk
Status: ASSIGNED → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → FIXED
Whiteboard: xf-to-branch

Updated

11 years ago
Keywords: fixed1.8.1

Updated

11 years ago
Keywords: fixed1.8.0.5

Updated

11 years ago
Whiteboard: xf-to-branch
You need to log in before you can comment on or make changes to this bug.