gecko-dev/storage
Lina Cambridge 2276deaa8d Bug 1539697 - Report more detailed errors in the mozStorage Rust binding. r=mak,tcsc
The `nsresult` codes that mozStorage returns are often too generic. For
example, `NS_ERROR_FAILURE` might be anything from a SQL syntax error
to an invalid column name in a trigger.

This commit adds a `Conn::call_and_wrap_error` helper that checks the
last SQLite error, and returns that instead of `nsresult`. Not all
errors are SQLite errors, however, so we only use this for mozStorage
methods that return `convertResultCode`.

Differential Revision: https://phabricator.services.mozilla.com/D25179

--HG--
extra : moz-landing-system : lando
2019-04-02 16:56:41 +00:00
..
build Bug 1524687: Part 12 - Convert everything else to static registration. r=erahm 2019-01-29 16:03:41 -08:00
rust Bug 1539697 - Report more detailed errors in the mozStorage Rust binding. r=mak,tcsc 2019-04-02 16:56:41 +00:00
test Bug 1539104 - Add a way to detect supported storage connection operations. r=mak 2019-04-02 18:49:21 +00:00
variant Bug 1482608 - Add basic Rust bindings for mozStorage. r=nika,asuth,mak 2019-03-25 04:49:18 +00:00
FileSystemModule.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
FileSystemModule.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
IStorageBindingParamsInternal.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
SQLCollations.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
SQLCollations.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
SQLiteMutex.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
StatementCache.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
StorageBaseStatementInternal.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
StorageBaseStatementInternal.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
TelemetryVFS.cpp Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre 2019-01-18 10:16:18 +01:00
VacuumManager.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
VacuumManager.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
Variant.cpp Bug 1490496 - implement XPCOM FFI for key-value storage r=nika,lina,mossop 2019-02-07 16:14:04 +00:00
Variant.h Bug 1490496 - implement XPCOM FFI for key-value storage r=nika,lina,mossop 2019-02-07 16:14:04 +00:00
Variant_inl.h Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre 2019-01-18 10:16:18 +01:00
moz.build Bug 1490496 - implement XPCOM FFI for key-value storage r=nika,lina,mossop 2019-02-07 16:14:04 +00:00
mozIStorageAggregateFunction.idl
mozIStorageAsyncConnection.idl Bug 1482608 - Add basic Rust bindings for mozStorage. r=nika,asuth,mak 2019-03-25 04:49:18 +00:00
mozIStorageAsyncStatement.idl
mozIStorageBaseStatement.idl
mozIStorageBindingParams.idl
mozIStorageBindingParamsArray.idl
mozIStorageCompletionCallback.idl
mozIStorageConnection.idl
mozIStorageError.idl
mozIStorageFunction.idl
mozIStoragePendingStatement.idl
mozIStorageProgressHandler.idl
mozIStorageResultSet.idl
mozIStorageRow.idl
mozIStorageService.idl
mozIStorageStatement.idl Bug 1482608 - Add basic Rust bindings for mozStorage. r=nika,asuth,mak 2019-03-25 04:49:18 +00:00
mozIStorageStatementCallback.idl
mozIStorageVacuumParticipant.idl
mozIStorageValueArray.idl
mozStorageArgValueArray.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageArgValueArray.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatement.cpp Bug 1526382 - Part 2: Make nsIClassInfo use Array<nsIIDRef> for 'interfaces', r=mccr8 2019-02-13 21:42:08 +00:00
mozStorageAsyncStatement.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatementExecution.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatementExecution.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatementJSHelper.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatementJSHelper.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatementParams.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageAsyncStatementParams.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageBindingParams.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageBindingParams.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageBindingParamsArray.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageBindingParamsArray.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageConnection.cpp Bug 1539104 - Add a way to detect supported storage connection operations. r=mak 2019-04-02 18:49:21 +00:00
mozStorageConnection.h Bug 1539104 - Add a way to detect supported storage connection operations. r=mak 2019-04-02 18:49:21 +00:00
mozStorageError.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageError.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageHelper.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStoragePrivateHelpers.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStoragePrivateHelpers.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageResultSet.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageResultSet.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageRow.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageRow.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageSQLFunctions.cpp Bug 1490496 - implement XPCOM FFI for key-value storage r=nika,lina,mossop 2019-02-07 16:14:04 +00:00
mozStorageSQLFunctions.h Bug 1513892 - Part 1: Cache usage in the database table; r=asuth 2018-12-21 06:26:25 +01:00
mozStorageService.cpp Bug 1539104 - Add a way to detect supported storage connection operations. r=mak 2019-04-02 18:49:21 +00:00
mozStorageService.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatement.cpp Bug 1482608 - Add basic Rust bindings for mozStorage. r=nika,asuth,mak 2019-03-25 04:49:18 +00:00
mozStorageStatement.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementData.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementJSHelper.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementJSHelper.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementParams.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementParams.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementRow.cpp Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
mozStorageStatementRow.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
storage.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00
style.txt
variantToSQLiteT_impl.h Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format 2018-11-30 11:46:48 +01:00