drydart / flutter_sqlcipher

SQLCipher database plugin for Flutter apps.
https://pub.dev/packages/flutter_sqlcipher
The Unlicense
66 stars 14 forks source link

crash on an exception when wrong database password provided #8

Open ramsestom opened 4 years ago

ramsestom commented 4 years ago

When trying to open a database with wrong password, the app crash on the following exception:

Exception has occurred. SqfliteDatabaseException (DatabaseException(file is not a database: , while compiling: select count(*) from sqlite_master;))

that happen at the rethrow; at line 110 in factory_mixin.dart

This happen even when sqflite.openDatabase() is called from inside a try block so I guess the error is not correctly handled all the way back to the openDatabasefunction.