Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ContentProvider 魅族有兼容性问题 #412

Open
SheepYoung opened this issue Nov 6, 2017 · 2 comments
Open

ContentProvider 魅族有兼容性问题 #412

SheepYoung opened this issue Nov 6, 2017 · 2 comments

Comments

@SheepYoung
Copy link

如题, 使用魅族(API level: 23 Flyme 6.2.0.0A)使用ContenProvider的时候报错:

android.database.sqlite.SQLiteCantOpenDatabaseException: unknown error (code 14): Could not open database
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteConnection.nativeOpen(Native Method)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteConnection.open(SQLiteConnection.java:220)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteConnection.open(SQLiteConnection.java:204)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteConnectionPool.openConnectionLocked(SQLiteConnectionPool.java:463)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteConnectionPool.open(SQLiteConnectionPool.java:185)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteConnectionPool.open(SQLiteConnectionPool.java:177)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteDatabase.openInner(SQLiteDatabase.java:840)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteDatabase.open(SQLiteDatabase.java:825)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteDatabase.openDatabase(SQLiteDatabase.java:718)
11-06 17:40:37.276 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteOpenHelper.getDatabaseLocked(SQLiteOpenHelper.java:234)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.database.sqlite.SQLiteOpenHelper.getReadableDatabase(SQLiteOpenHelper.java:187)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at com.owncloud.android.providers.FileContentProvider.query(FileContentProvider.java:352)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.content.ContentProvider.query(ContentProvider.java:1140)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.content.ContentProvider$Transport.query(ContentProvider.java:262)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.content.ContentResolver.query(ContentResolver.java:506)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at android.content.ContentResolver.query(ContentResolver.java:441)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at com.owncloud.android.datamodel.FileDataStorageManager.getCapabilityCursorForAccount(FileDataStorageManager.java:1975)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at com.owncloud.android.datamodel.FileDataStorageManager.getCapability(FileDataStorageManager.java:1998)
11-06 17:40:37.277 4607-4607/com.microvideo.mivi:PluginP03 W/System.err: at com.owncloud.android.ui.activity.FileActivity.onAccountSet(FileActivity.java:762)

@SheepYoung
Copy link
Author

另外我还发现一些其他的error:
E/SharedPreferencesImpl: Couldn't create directory for SharedPreferences file /data/user/0/com.owncloud.android/shared_prefs/oc_flag_file.xml

E/SQLiteLog: (14) os_unix.c:31322: (2) open(/data/user/0/com.owncloud.android/databases/filelist) -
/SQLiteDatabase: Failed to open database '/data/user/0/com.owncloud.android/databases/filelist'.

我到shell里面查看:
root@M2E:/data/user/0 # ls -l com.own*
com.own*: No such file or directory

root@M2E:/data/user/0 # find . -name "com.own*"
./com.microvideo.mivi/Plugin/com.owncloud.android

应该是插件创建User文件失败了,

@SheepYoung
Copy link
Author

对比其他手机(Nexus 6P 6.0.1):
root@angler:/data/data/com.microvideo.mivi/Plugin/com.owncloud.android/data/com.owncloud.android # ls
databases
files
shared_prefs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant