Open palevomr opened 9 years ago
Did you force shutdown the device or force stop your app while it was maybe writing data?
This happened to me as well. Is there a way to avoid having that?
Can you give more details? Was the db saved in default internal directory, or was it elsewhere? Was the phone forced shutdown? Was it's battery removed while on? Was the app force closed, by hand or by crash? On which phone? Android version? Do you know any steps to reproduce? Can you provide a code snippet?
After a couple of days, app could not get access to snappyDB as it throws next exception.
/System.err(21591): Caused by: com.snappydb.SnappydbException: Failed to open/create database: Corruption: CURRENT file does not end with newline W/System.err(21591): at com.snappydb.internal.DBImpl.__open(Native Method) W/System.err(21591): at com.snappydb.internal.DBImpl.(DBImpl.java:53)
W/System.err(21591): at com.snappydb.DBFactory.open(DBFactory.java:40)
W/System.err(21591): at com.snappydb.DBFactory.open(DBFactory.java:65)
W/System.err(21591): at com.snappydb.DBFactory.open(DBFactory.java:77)
Using the last version of snappyDB(0.5.2)
For now, was reproduced three times on Fly IQ4410 Quad Android 4.2.1