Closed
Bug 734401
Opened 13 years ago
Closed 8 years ago
Protect async queries from syntax errors
Categories
(Toolkit :: Places, defect)
Toolkit
Places
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: mak, Unassigned)
Details
When building and executing an async query no check is done on the query itself, since it's prepared on the first execution. This means that a typo/syntax would be invisible up to the runtime point.
To provide some sort of protection we should have no async queries without a callback (thus provide a default no-op callback) and fatal assert in all the handleError methods.
Reporter | ||
Comment 1•13 years ago
|
||
An alternative may be to hook up something in storage, a MOZ_ASSERT in it would be much better, though it's common to use it to test queries (for example in SQLite Manager) ans fatal assertions there would be quite bad.
A possibility could be to decorate the statements with a comment like
/* assert parsing */ SELECT ...
and parse the comment in debug mode to check if it should assert.
Reporter | ||
Updated•8 years ago
|
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•