mirror of
https://github.com/status-im/sqlcipher.git
synced 2025-02-24 01:38:09 +00:00
fix segfault when calling sqlite3_rekey before sqlite3_key - openssl should be initialized on either call
This commit is contained in:
parent
e47eea5646
commit
3ce6037365
@ -488,6 +488,7 @@ int sqlite3_key(sqlite3 *db, const void *pKey, int nKey) {
|
||||
*/
|
||||
int sqlite3_rekey(sqlite3 *db, const void *pKey, int nKey) {
|
||||
CODEC_TRACE(("sqlite3_rekey: entered db=%d pKey=%s, nKey=%d\n", db, pKey, nKey));
|
||||
OpenSSL_add_all_algorithms();
|
||||
if(db && pKey && nKey) {
|
||||
struct Db *pDb = &db->aDb[0];
|
||||
CODEC_TRACE(("sqlite3_rekey: database pDb=%d\n", pDb));
|
||||
|
Loading…
x
Reference in New Issue
Block a user