| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
have to remember to install MainHook.
BUG=None
Review URL: https://chromiumcodereview.appspot.com/12321117
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@188376 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
| |
TBR=sky
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@184344 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Raze() clears out the database, but cannot be called within a
transaction. Close() can only be called once all statements have
cleared. Error callbacks happen while executing statements (thus
often in a transaction, and at least one statement is outstanding).
RazeAndClose() forcibly breaks outstanding transactions, calls Raze()
to clear the database, then calls Close() to close the handle. All
future operations against the database should fail safely (without
affecting storage and without crashing).
BUG=166419, 136846
Review URL: https://chromiumcodereview.appspot.com/12096073
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@181152 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Automated clean up of style checker errors that were missed due to the plugin
not being executed on implementation files.
BUG=115047
Review URL: https://chromiumcodereview.appspot.com/12211033
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@181004 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
| |
This updates headers that forward-declare it and a few random places to use the namespace explicitly. There us a using declaration in file_path.h that makes the rest compile, which we can do in future passes.
Review URL: https://codereview.chromium.org/12163003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@180245 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
So client code of histogram will see a simpler interface. This also makes adding SparseHistogram to existing metrics framework possible.
This CL depends on https://codereview.chromium.org/11682003/
So please review that one first.
TBR=sky@chromium.org,erikwright@chromium.org
BUG=139612
Review URL: https://chromiumcodereview.appspot.com/11615008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@178242 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
BUG=chromium:158178
TEST=units,make sure such SEGV doesnt happen on x86-generic-bot (where it pops periodically now)
Review URL: https://chromiumcodereview.appspot.com/11886065
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177399 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
BUG=166496
BUG=167187
TBR=shess
Review URL: https://chromiumcodereview.appspot.com/11860013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@176397 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously there was a convoluted template system to unique histogram names for purposes of tracking database errors separately. This was needed due to the static cache used by the histogram macros. Instead, just log the histogram manually without using a static cache.
Additionally, pull the histogram functionality right up into the connection, rather than requiring formalized delegation to get it.
BUG=none
Review URL: https://chromiumcodereview.appspot.com/11474030
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175055 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently the histograms are binned together for all errors, but
knowing open-specific errors is helpful for dealing with problems on
open.
BUG=159490
Review URL: https://chromiumcodereview.appspot.com/11468024
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@171862 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
Also add to base namespace.
BUG=
Review URL: https://codereview.chromium.org/11359217
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@168281 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
KillDatabaseErrorDelegate cannot Raze() if the corruption is found
while opening the databse, because by the time the callback happens
the database has been closed. Add support for setting a flag for the
database-opening code to check.
Additionally, errors detected when executing or preparing statements
were not forwarded to the error delegate, which could let them sneak
by without notice.
BUG=159490
Review URL: https://chromiumcodereview.appspot.com/11358170
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@167023 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Corruptions resulting from the first page showing a different database
size than the filesystem shows cause very basic functions to fail.
This does fewer queries against the corrupt database, and also enables
a magic pragma to let it make better progress.
BUG=159490
Review URL: https://chromiumcodereview.appspot.com/11369126
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@167019 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ErrorDelegate
BUG=151841
Test=None
R=shess, erikwright
TBR=cpu
Review URL: https://chromiumcodereview.appspot.com/11141012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@162647 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=151841
Test=None
R=shess
TBR=jamesr,erikwright
Review URL: https://chromiumcodereview.appspot.com/11111021
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@162443 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On Android, some GYP client targets were explicitly depending on both the
native and Java sides of a library.
This removes the dependencies to {base,net}_java and make the native side
('base' and 'net) of these libraries depend on their Java counterpart.
On Android it rarely makes sense to depend on a single side of a Java/C++
library.
The {base,net}_java can now be considered as "private" targets although GYP
does not support this concept unfortunately (AFAICT).
Note that I made sure that the resulting APKs' size is unchanged.
Additionally, this CL removes 'base_java' (i.e. does not replace it with
'base') from the targets including 'build/apk_test.gypi'. This dependency
should not have been there (in the wrong layer) in the first place. It's needed
by ChromeNativeTestActivity.java which clients should not know about.
BUG=146323
TBR=lipalani,sky,willchan,brettw
Review URL: https://chromiumcodereview.appspot.com/10913083
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@155737 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SQLite-based database.
The protobuf-based cache was only being read at startup and written at shutdown. (Except that when the cache could not be read at startup the cache would immediately be saved upon private data reconstruction from the History database.) With the new implementation using an SQLite database for the HQP cache the private data will be restored from the cache database at startup and continually updated during normal operation. There is no need to flush or write the cache at shutdown as it is constantly kept up-to-date.
Detailed comments about the changes made in this CL can be found in the document shared separately.
Previous reviewers: sky, pkasting, shess.
BUG=95686, 95876, 131668
TEST=New tests added, old tests updated, all tests pass.
To manually verify changes:
NOTE: For tests using chrome://omnibox be sure to check the "Show results per provider" and then look at the results for the HistoryQuickProvider.
1) New visits: Type an URL never visited before. Bring up new tab. Start typing the URL or parts of the page title or both and verify that the page is offered as a suggestion.
2) New visits: Type an URL never visited before. Do search using chrome://omnibox. New visit should show.
3) Delete visit: Visit some pages and verify they have been recorded. Bring up history and delete one of the visits. Check via chrome://omnibox that it was deleted.
4) Clear history: Visit some pages. Clear the visit history. Check via chrome://omnibox that none of the visits are still returned by the HQP.
5) Updated site: Create a local page and visit it. Search using chrome://omnibox by page title and verify it can be found. Change the page title dramatically and revisit the page. Verify via chrome://oomnibox that the page can be found by words from the new title.
Previously reviewed as: http://codereview.chromium.org/10477018/.
10477018 was reverted due to memory leaks detected by build bots.
Review URL: https://chromiumcodereview.appspot.com/10837244
TBR=mrossetti@chromium.org
This is causing performance regressions across a range of perf bots.
Review URL: https://chromiumcodereview.appspot.com/10872032
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@152963 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
database.
The protobuf-based cache was only being read at startup and written at shutdown. (Except that when the cache could not be read at startup the cache would immediately be saved upon private data reconstruction from the History database.) With the new implementation using an SQLite database for the HQP cache the private data will be restored from the cache database at startup and continually updated during normal operation. There is no need to flush or write the cache at shutdown as it is constantly kept up-to-date.
Detailed comments about the changes made in this CL can be found in the document shared separately.
Previous reviewers: sky, pkasting, shess.
BUG=95686, 95876, 131668
TEST=New tests added, old tests updated, all tests pass.
To manually verify changes:
NOTE: For tests using chrome://omnibox be sure to check the "Show results per provider" and then look at the results for the HistoryQuickProvider.
1) New visits: Type an URL never visited before. Bring up new tab. Start typing the URL or parts of the page title or both and verify that the page is offered as a suggestion.
2) New visits: Type an URL never visited before. Do search using chrome://omnibox. New visit should show.
3) Delete visit: Visit some pages and verify they have been recorded. Bring up history and delete one of the visits. Check via chrome://omnibox that it was deleted.
4) Clear history: Visit some pages. Clear the visit history. Check via chrome://omnibox that none of the visits are still returned by the HQP.
5) Updated site: Create a local page and visit it. Search using chrome://omnibox by page title and verify it can be found. Change the page title dramatically and revisit the page. Verify via chrome://oomnibox that the page can be found by words from the new title.
Previously reviewed as: http://codereview.chromium.org/10477018/.
10477018 was reverted due to memory leaks detected by build bots.
Review URL: https://chromiumcodereview.appspot.com/10837244
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@152946 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SQLite-based database.
The protobuf-based cache was only being read at startup and written at shutdown. (Except that when the cache could not be read at startup the cache would immediately be saved upon private data reconstruction from the History database.) With the new implementation using an SQLite database for the HQP cache the private data will be restored from the cache database at startup and continually updated during normal operation. There is no need to flush or write the cache at shutdown as it is constantly kept up-to-date.
Detailed comments about the changes made in this CL can be found in the document shared separately.
Reviewer suggestions:
sky: for proper thread usage. Also chrome/browser/ui/ and chrome/browser/visitedlink/.
pkasting: for whatever you'd like to check over but please look over the design document shared separately.
shess: please take a look at database usage in chrome/browser/history/in_memory_url_cache_database.h/.cc.
BUG=95686,95876,131668
TEST=New tests added, old tests updated, all tests pass.
To manually verify changes:
NOTE: For tests using chrome://omnibox be sure to check the "Show results per provider" and then look at the results for the HistoryQuickProvider.
1) New visits: Type an URL never visited before. Bring up new tab. Start typing the URL or parts of the page title or both and verify that the page is offered as a suggestion.
2) New visits: Type an URL never visited before. Do search using chrome://omnibox. New visit should show.
3) Delete visit: Visit some pages and verify they have been recorded. Bring up history and delete one of the visits. Check via chrome://omnibox that it was deleted.
4) Clear history: Visit some pages. Clear the visit history. Check via chrome://omnibox that none of the visits are still returned by the HQP.
5) Updated site: Create a local page and visit it. Search using chrome://omnibox by page title and verify it can be found. Change the page title dramatically and revisit the page. Verify via chrome://oomnibox that the page can be found by words from the new title.
Review URL: https://chromiumcodereview.appspot.com/10477018
TBR=mrossetti@chromium.org
Review URL: https://chromiumcodereview.appspot.com/10830297
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@151424 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
database.
The protobuf-based cache was only being read at startup and written at shutdown. (Except that when the cache could not be read at startup the cache would immediately be saved upon private data reconstruction from the History database.) With the new implementation using an SQLite database for the HQP cache the private data will be restored from the cache database at startup and continually updated during normal operation. There is no need to flush or write the cache at shutdown as it is constantly kept up-to-date.
Detailed comments about the changes made in this CL can be found in the document shared separately.
Reviewer suggestions:
sky: for proper thread usage. Also chrome/browser/ui/ and chrome/browser/visitedlink/.
pkasting: for whatever you'd like to check over but please look over the design document shared separately.
shess: please take a look at database usage in chrome/browser/history/in_memory_url_cache_database.h/.cc.
BUG=95686,95876,131668
TEST=New tests added, old tests updated, all tests pass.
To manually verify changes:
NOTE: For tests using chrome://omnibox be sure to check the "Show results per provider" and then look at the results for the HistoryQuickProvider.
1) New visits: Type an URL never visited before. Bring up new tab. Start typing the URL or parts of the page title or both and verify that the page is offered as a suggestion.
2) New visits: Type an URL never visited before. Do search using chrome://omnibox. New visit should show.
3) Delete visit: Visit some pages and verify they have been recorded. Bring up history and delete one of the visits. Check via chrome://omnibox that it was deleted.
4) Clear history: Visit some pages. Clear the visit history. Check via chrome://omnibox that none of the visits are still returned by the HQP.
5) Updated site: Create a local page and visit it. Search using chrome://omnibox by page title and verify it can be found. Change the page title dramatically and revisit the page. Verify via chrome://oomnibox that the page can be found by words from the new title.
Review URL: https://chromiumcodereview.appspot.com/10477018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@151419 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Both java.gypi and apk_test.gypi expect the jar path in
input_jars_paths. This means that we were specifying the dependence in
both 'dependencies' and 'input_jars_paths'. This change makes it so that
we don't need that redundancy.
Also, make java.gypi use input_jars_paths in its input so that we
actually rebuild targets when we should.
BUG=136756
Review URL: https://chromiumcodereview.appspot.com/10837143
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@150850 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Includes a change to sql/Connection to propagate the auto_vacuum pragma across a raze operation. Also updates test expectations.
BUG=137853
Review URL: https://chromiumcodereview.appspot.com/10829062
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@150128 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
allowing IO access.
Also expanded scope of ScopedAllowIO in
SQLiteServerBoundCertStore::Backend::Load() to cover SQLite functions.
And added ScopedAllowIO to PasswordStoreFactory::BuildServiceInstanceFor() --
it calls LoginDatabase::Init() which should be executed on DB thread.
This is a reland of
https://src.chromium.org/viewvc/chrome?view=rev&revision=147309
which was reverted because of missing ScopedAllowIO in PasswordStoreFactory.
Patch from Pavel Ivanov <paivanof@gmail.com>
BUG=75232, 52909, 137961, 138903
TEST=no test fails with message "Function marked as IO-only was called from a thread that disallows IO!"
Review URL: https://chromiumcodereview.appspot.com/10824008
Patch from Pavel Ivanov <paivanof@gmail.com>.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148788 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
BUG=None
TEST=None
Review URL: https://chromiumcodereview.appspot.com/10696219
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148136 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Many tests are failed due to sqlite errors on Android.
The reason is that sqlite need a temporary directory to
store internal temporary files. However, Android doesn't
have this kind of directory while Linux has /var/tmp.
To fix this, use in-memory temporary files. It also includes:
1) Add one unit test in sql unittests to reproduce this
issue for Android.
2) Remove those disabled cases for content unitests on
Android.
BUG=
TEST=run_tests.py -s sql_unittests; run_test.py -s net_unittests
Review URL: https://chromiumcodereview.appspot.com/10809015
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148064 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The comments in these cases used incorrect reasoning for why the
const_cast<> was safe. Whether the SQL statements modify the database
is irrelevant. Add an internal helper to allow them to correctly
accomplish things in a const situation.
BUG=none
TEST=none
Review URL: https://chromiumcodereview.appspot.com/10736042
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148031 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
executed on a thread allowing IO access.
Expand scope of ScopedAllowIO in the only place where SQLite functions are used on UI thread.
Patch from Pavel Ivanov <paivanof@gmail.com>
BUG=75232,52909,137961
TEST=no test fails with message "Function marked as IO-only was called from a thread that disallows IO!"
Review URL: https://chromiumcodereview.appspot.com/10540155
Patch from Pavel Ivanov <paivanof@gmail.com>.
TBR=shess@chromium.org
Review URL: https://chromiumcodereview.appspot.com/10806025
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@147340 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
allowing IO access.
Expand scope of ScopedAllowIO in the only place where SQLite functions are used on UI thread.
Patch from Pavel Ivanov <paivanof@gmail.com>
BUG=75232,52909
TEST=no test fails with message "Function marked as IO-only was called from a thread that disallows IO!"
Review URL: https://chromiumcodereview.appspot.com/10540155
Patch from Pavel Ivanov <paivanof@gmail.com>.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@147309 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
BUG=None
TEST=None
Review URL: https://chromiumcodereview.appspot.com/10702203
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@146604 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
For context see this thread:
https://groups.google.com/a/chromium.org/forum/?fromgroups#!topic/chromium-dev/RMcVNGjB4II
TBR=thakis,pkasting,jam
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@146163 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Patch from Pavel Ivanov <paivanof@gmail.com>
BUG=130498
TEST=On Linux /tmp/SQLStatementTest.db-journal is not left after execution.
Review URL: https://chromiumcodereview.appspot.com/10542096
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@141849 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=125059
Follow-up to: http://codereview.chromium.org/10399126/
TEST=
Review URL: https://chromiumcodereview.appspot.com/10443068
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@139727 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Original CL http://codereview.chromium.org/7891025 , http://crrev.com/101034
The hypothesis discussed in that CL seems proven out, as the
shutdown-hang crashes mostly moved from sqlite3_close() into
sqlite3_95527().
BUG=95527
TEST=Monitor crash in bug, see if it changes.
Review URL: https://chromiumcodereview.appspot.com/9845034
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@137989 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With the current setup, if you have a header file my_class.h
class BASE_EXPORT MyClass {
public:
void MyInlineMethod() { /* do stuff, inline */ }
};
then every cc file that includes my_class.h will have a public symbol
for MyInlineMethod (because inline methods need to be emitted to
every translation unit, and the linker sorts them out). With the
components build, the linker can't decide to drop these inline methods,
so every .so that uses this header file will have the same public symbol.
With this proposed change, the symbol will only be visible in the target
the header file belongs to, and it will be hidden in all other components.
That's cleaner, and it also prevents accident hidden dependencies (say
target A depends on B, and B depends on C. A accidentally uses an inline
function from a class in C. With this change, that would result in a linker
error, and an explicit dependency from A on C would have to be added).
Also add a missing CHROMEOS_IMPLEMENTATION define which went
unnoticed until now.
BUG=90078
TEST=Things still build.
TBR=ben, tony, viettrungluu, thestig, agl, willchan
Review URL: https://chromiumcodereview.appspot.com/10386108
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@137130 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
BUG=123295
TEST=none
Review URL: http://codereview.chromium.org/10038045
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@134456 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
clearing bound variables, so and current row is reset to the beginning.
It is used to support the Andorid' sqlite cursor feature which could move the cursor around the result set.
BUG=
TEST=Added a new test.
TBR=agl,akalin,michaeln
Review URL: http://codereview.chromium.org/10171014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@133985 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Wraps up the notion of reseting a database in a way which respects
SQLite locking constraints and doesn't require closing the database.
A similar outcome could be managed using filesystem operations, which
requires coordination between clients of the database to make sure
that no corruption occurs due to incorrect handling of -journal files.
Also, Windows pins files until the last handle closes, making that
approach challenging in some cases.
BUG=none
TEST=none
Review URL: https://chromiumcodereview.appspot.com/9768006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@131167 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix issue that the transaction can not be started if the nesting_transaction rollback.
BUG=
TEST=Add a new test to cover this case. Also pass the existing tests.
Review URL: http://codereview.chromium.org/9839021
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@128352 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The default is DELETE mode, in which the delete commits the
transaction. PERSIST keeps the files around, but zeros out the
header.
journal_mode has been in SQLite since 3.5.9 (2008), so even very old
versions of Chromium should interact well.
BUG=118470
TEST=none
Review URL: http://codereview.chromium.org/9702092
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@127366 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
R=shess@chromium.org, gbillock@chromium.org, erikwright@chromium.org
BUG=88315
Review URL: https://chromiumcodereview.appspot.com/9666026
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@126285 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
http://crbug.com/111376 happened because a crash between creation and
population of the meta table could leave a meta table returning 0 for
the version numbers, even though no client ever stored 0 for the
versions. This makes creation and population atomic.
Additionally, version numbers are restricted to positive values, to
prevent this case from being masked in the future.
BUG=116306
TEST=none
Review URL: http://codereview.chromium.org/9592026
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125557 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is because I wondered if they were nestable, looked here for documentation to that affect, didn't see any, and thus assumed they weren't (I also googled sqlite3 nested transactions and saw that they were not natively supported by the DB - I think that the conclusion I drew is probably the one that most readers would have drawn).
BUG=None
TEST=Ask a random developer if sql::Transaction transactions may be nested.
Review URL: http://codereview.chromium.org/9624006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125448 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
used in the TemplateURL refactoring changes.
Reorder function definitions to match declaration order. Shorten a few bits.
BUG=none
TEST=none
Review URL: https://chromiumcodereview.appspot.com/9584031
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@124823 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix leftover users of operators.
R=shess@chromium.org
BUG=None
TEST=sql_unittests,unit_tests
Review URL: http://codereview.chromium.org/9433022
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123609 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The existing code DCHECKs that all statement handles are closed, but
if any statements handles are open, they have a weak reference which
can end up referring to a deallocated Connection instance.
Additionally, that change allows the code to reach
DeleteSessionCookies() without crashing, so add a guard there.
BUG=111376
TEST=fewer crashes.
Review URL: http://codereview.chromium.org/9402035
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123536 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sql::Statement maintains a weak ref to the associated sql::Connection,
meaning that if the database and statement are destructed in the wrong
order, a use-after-free can result. sql::Statement::Clear() allows
resetting the statement to the default-constructed state.
BUG=111376
TEST=fewer crashes.
Review URL: http://codereview.chromium.org/9418021
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@122430 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
Android does not have toLower in it's <algorithm>, use
StringToLowerASCII instead.
Review URL: http://codereview.chromium.org/9384004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121505 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Make sure to close the database even if we failed to open it.
BUG=113658
Review URL: http://codereview.chromium.org/9381011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121501 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a class that can read/write a local storage database in the same format as WebCore's StorageArea.
Also add a method to sql::Statement to query the declared type of a column and a method to return a string16 from a Blob.
BUG=106763
Review URL: http://codereview.chromium.org/9159020
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121442 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Goal is to encourage callers to handle errors, especially in cases
like schema changes, where dropped errors can result in broken
databases.
Many CREATE INDEX calls where ignoring errors rather than checking if
the index already existed before creating it. Recoded those to CREATE
INDEX IF NOT EXISTS, which is for exactly this purpose.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/9005036
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@115725 0039d316-1c4b-4281-b951-d872f2087c98
|