1. 23 May, 2013 1 commit
  2. 02 May, 2013 2 commits
  3. 06 Mar, 2013 2 commits
  4. 07 Feb, 2013 2 commits
  5. 27 Dec, 2012 1 commit
    • Yongil Jang's avatar
      Fix bugs of database corruption following IO error on systems supporting atomic-write · 6ab557bd
      Yongil Jang authored
      SQLite on Android uses AUTO_VACUUM option.
      When the disk space is critically low and atomic-write option is enabled,
      SQLite writes transactions that modify a single database page on disk
      without creating a journal file.
      
      Due to a bug, if an IO or disk full error occurs while transferring
      the contents to disk, the single page that was modified in the cache
      is not being rolled back - cache corruption.
      As a result, applications get a database corruption exception
      for next database transactions.
      
      This patch changes createFile() to close pReal in case of IO error.
      Therefore, cache is being rolled back.
      
      This patch is originated from www.sqlite.org.
      (URL: http://www.sqlite.org/src/tktview?name=df678d738a)
      
      Change-Id: Ieecda65d8458cb591bd4d89d8b423a4479f50ea8
      6ab557bd
  6. 10 Dec, 2012 1 commit
    • git-lg-database.lge.com's avatar
      Fix bugs of sqlite that returns SIGBUS on disk full in WAL mode · 1eb051da
      git-lg-database.lge.com authored
      Attempts to prepare a query on a WAL database when the disk space is
      critically low result in the process killed with SIGBUS.
      The crash happens in walIndexWriteHdr invoked from walIndexRecover.
      
      Some Providers that using WAL mode like as SettingsProvider and MediaProvider
      get failed in case of disk full with SIGBUS.
      This patch changes unixShmMap() to call fallocate() instead of ftruncate.
      In case of disk full, fallocate() will return SQLITE_FULL.
      
      This patch is originated from www.sqlite.org.
      (URL: http://www.sqlite.org/src/info/5eaa61ea18)
      To simplify error status, returned error code is changed
      from SQLITE_IOERR_SHMSIZE to SQLITE_FULL.
      
      [written by Yongil Jang <yi.jang@lge.com>]
      
      Change-Id: Idf3cbdab1ed4a4f2bc1b2b93ab6d8900edc7ee05
      1eb051da
  7. 06 Dec, 2012 1 commit
    • git-lg-database.lge.com's avatar
      Change android fix for fts backward compatibility patch of sqlite3.c for newer sqlite version · 123fdf46
      git-lg-database.lge.com authored
      From earlier version of Android, patch of FTS3 backwards compatibility is kept until now.
      But, this patch doesn't work well on newer version of sqlite3 (3.7.13~) when it was used.
      Currently, sqlite3Fts3Init function is called three times to register "fts1", "fts2" and "fts3" with the same module.
      It worked very well on earlier version of sqlite but not for newer version.
      hashDestroy() function makes an error when it is called after the first destroy of fts3Module.
      sqlite3Fts3Init() function initializes "fts4" module and it is called three times to initialize "fts1" and "fts2".
      
      This patch contains changed source code of sqlite3Fts3Init() function to be called once.
      
      [written by Yongil Jang <yi.jang@lge.com>]
      
      Change-Id: I55f522b55f421f73e83508cfc5e08514bd7da925
      123fdf46
  8. 15 Jun, 2012 1 commit
  9. 15 May, 2012 2 commits
  10. 12 May, 2012 1 commit
  11. 11 May, 2012 1 commit
    • Jeff Brown's avatar
      Enable the powersafe overwrite assumption. · 2d758ba4
      Jeff Brown authored
      This change improves performance on certain kinds of transactions
      such as UPDATEs by allowing SQLite to make stronger assumptions
      about data integrity on the disk.
      
      The powersafe overwrite assumption demands that when a byte is
      written to a file and a power event occurs then the only bytes
      that may have been modified are the ones that were being written.
      
      In absense of the powersafe overwrite assumption, SQLite assumes
      that a write of any range of bytes within a disk sector may
      potentially cause the rest of the sector to be corrupted.  SQLite
      needs to do extra work to compensate for this problem, which adds
      overhead to certain transactions.
      
      On flash devices, writing a byte causes the sector to be rewritten
      somewhere else on the device.  Eventually the old sector may be
      erased and reused.  The powersafe overwrite assumption therefore
      holds as long as the flash device never leaves behind (observable)
      half-written sectors in case of a power event.  This is a fairly
      safe assumption to make.  Some flash devices apparently include
      measures to ensure that the last write fully completes when
      power is interrupted.  In any case, the window of opportunity
      for corruption to occur is very small.
      
      Bug: 6484633
      Change-Id: I0b0ef664b3a2a0e85c6099f0130d0affc5562be5
      2d758ba4
  12. 01 May, 2012 3 commits
  13. 20 Apr, 2012 2 commits
    • Jeff Brown's avatar
      Upgrade to SQLite 3.7.11. · c82acac4
      Jeff Brown authored
      Bug: 6176510
      Change-Id: I482e980b3377a9606fc23e72fd25d0c648f718d4
      c82acac4
    • Jeff Brown's avatar
      Extract Android diffs. · 0bc48368
      Jeff Brown authored
      No code changes.  This is just preparing for an upgrade.
      
      Bug: 6176510
      Change-Id: I5be7cf74e8d72d1bdb16b09b6bee8330c67ed7fc
      0bc48368
  14. 02 Apr, 2012 6 commits
  15. 26 Mar, 2012 2 commits
  16. 01 Mar, 2012 1 commit
    • Jeff Brown's avatar
      Use fdatasync() to improve performance. · 3ab5bec5
      Jeff Brown authored
      Linux has a working fdatasync() so we should use it!
      This change alone improves performance by around 20% by reducing
      the number of synchronous I/O writes of irrelevant metadata
      changes.
      
      Change-Id: Iebe0c32a7e018ec0ced2347b7d62b2b7dc5aa376
      3ab5bec5
  17. 01 Feb, 2012 3 commits
  18. 26 Jan, 2012 1 commit
  19. 20 Jan, 2012 4 commits
    • Jeff Brown's avatar
      Tweak SQLite configuration options. · 9e7798db
      Jeff Brown authored
      Turn off stuff we don't need.
      Enable FTS4.
      Enable ICU tokenizer.
      
      Bug: 5530406
      Bug: 5465099
      Change-Id: Idcc52050a4d048a64bfe8484e419dc8d2b27d6ed
      9e7798db
    • Jeff Brown's avatar
      Remove custom SQLITE_UNCLOSED error code. · e667f09e
      Jeff Brown authored
      This error code was introduced at some point to help track when
      a database could not be closed because a statement was not finalized.
      Now that the DB wrappers have been rewritten, it is technically no longer
      possible for this to happen, so we can remove this.
      
      Change-Id: Ia3c8167a0af522c852adbbd15c83c3c8f5732b26
      e667f09e
    • Jeff Brown's avatar
      Fix pread64 / pwrite64 signatures for Bionic. · af4ab8b2
      Jeff Brown authored
      Change-Id: I67183b854c34e9436ff604d0fd73b4ec8ee414f2
      af4ab8b2
    • Jeff Brown's avatar
      Upgrade SQLite to 3.7.10. · 90ed05d9
      Jeff Brown authored
      Ported all original Android-specific patches.
      
      Change-Id: I2c5801a92d783e2c5cba72147d9fb777ad7c8443
      90ed05d9
  20. 06 Jan, 2012 1 commit
  21. 03 Jan, 2012 1 commit
  22. 17 Dec, 2011 1 commit