Issue warning for deprecated PRAGMA cipher command

This commit is contained in:
Nick Parker 2016-03-03 11:23:11 -06:00
parent ac840a9ae0
commit bc9fda6b26
1 changed files with 4 additions and 0 deletions

View File

@ -144,6 +144,10 @@ int sqlcipher_codec_pragma(sqlite3* db, int iDb, Parse *pParse, const char *zLef
if(ctx) {
if( zRight ) {
sqlcipher_codec_ctx_set_cipher(ctx, zRight, 2); // change cipher for both
char *pragma_cipher_deprecated_msg = "PRAGMA cipher command is deprecated, please remove from usage.";
codec_vdbe_return_static_string(pParse, "cipher", pragma_cipher_deprecated_msg);
sqlite3_log(SQLITE_WARNING, pragma_cipher_deprecated_msg);
return SQLITE_ERROR;
}else {
codec_vdbe_return_static_string(pParse, "cipher",
sqlcipher_codec_ctx_get_cipher(ctx, 2));