Skip to content

Commit 92898bf

Browse files
Update to SQLCipher for Android 3.5.0
1 parent 582267e commit 92898bf

File tree

13 files changed

+274
-224
lines changed

13 files changed

+274
-224
lines changed

.idea/workspace.xml

Lines changed: 201 additions & 222 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/hello.db

2 KB
Binary file not shown.

assets/icudt46l.zip

-2.2 MB
Binary file not shown.

libs/armeabi-v7a/libsqlcipher.so

108 Bytes
Binary file not shown.

libs/armeabi/libsqlcipher.so

108 Bytes
Binary file not shown.

libs/sqlcipher-javadoc.jar

-164 KB
Binary file not shown.

libs/sqlcipher.jar

593 Bytes
Binary file not shown.

libs/x86/libsqlcipher.so

-7.89 KB
Binary file not shown.

src/main/java/net/zetetic/ZeteticApplication.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public void prepareDatabaseEnvironment(){
5353
public SQLiteDatabase createDatabase(File databaseFile){
5454
Log.i(TAG, "Entered ZeteticApplication::createDatabase");
5555
Log.i(TAG, "Before SQLiteDatabase.openOrCreateDatabase");
56-
return SQLiteDatabase.openOrCreateDatabase(databaseFile, DATABASE_PASSWORD, null);
56+
return SQLiteDatabase.openOrCreateDatabase(databaseFile.getPath(), DATABASE_PASSWORD, null);
5757
}
5858

5959
public void extractAssetToDatabaseDirectory(String fileName) throws IOException {

src/main/java/net/zetetic/tests/MigrateDatabaseFrom1xFormatToCurrentFormat.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
import net.zetetic.ZeteticApplication;
77

88
import java.io.File;
9+
import java.nio.ByteBuffer;
10+
import java.nio.CharBuffer;
11+
import java.nio.charset.Charset;
912

1013
public class MigrateDatabaseFrom1xFormatToCurrentFormat extends SQLCipherTest {
1114

@@ -22,7 +25,7 @@ public void postKey(SQLiteDatabase database) {
2225
database.rawExecSQL("PRAGMA cipher_migrate;");
2326
}
2427
};
25-
SQLiteDatabase source = SQLiteDatabase.openOrCreateDatabase(sourceDatabase, password, null, hook);
28+
SQLiteDatabase source = SQLiteDatabase.openOrCreateDatabase(sourceDatabase.getPath(), password, null, hook);
2629
Cursor result = source.rawQuery("select * from t1", new String[]{});
2730
if(result != null){
2831
result.moveToFirst();

0 commit comments

Comments
 (0)