mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-27 07:59:20 +00:00
Invert direction from old messages, because iOS was storing direction in the opposite manner than Linphone core
This commit is contained in:
parent
cda6c57dc9
commit
6f86da2e8e
1 changed files with 8 additions and 0 deletions
|
|
@ -371,6 +371,14 @@ static int check_should_migrate_images(void* data ,int argc,char** argv,char** c
|
|||
goto exit_dbmigration;
|
||||
}
|
||||
|
||||
// invert direction of old messages, because iOS was storing the direction flag incorrectly
|
||||
const char* invert_direction = "UPDATE history SET direction = NOT direction";
|
||||
if( sqlite3_exec(newDb, invert_direction, NULL, NULL, &errMsg) != SQLITE_OK){
|
||||
[LinphoneLogger log: LinphoneLoggerError format:@"Inverting direction failed, error[%s]", errMsg];
|
||||
sqlite3_free(errMsg);
|
||||
goto exit_dbmigration;
|
||||
}
|
||||
|
||||
// replace empty from: or to: by the current identity.
|
||||
if( default_proxy ){
|
||||
identity = linphone_proxy_config_get_identity(default_proxy);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue