mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
Fix crashes when sending chats to strange addresses
This commit is contained in:
parent
e389a03405
commit
6a82937bbd
2 changed files with 8 additions and 2 deletions
|
|
@ -292,7 +292,10 @@ static UICompositeViewDescription *compositeDescription = nil;
|
|||
|
||||
// Display name
|
||||
if(displayName == nil) {
|
||||
displayName = [NSString stringWithUTF8String:linphone_address_get_username(linphoneAddress)];
|
||||
const char* username = linphone_address_get_username(linphoneAddress);
|
||||
char* address = linphone_address_as_string(linphoneAddress);
|
||||
displayName = [NSString stringWithUTF8String:username?:address];
|
||||
ms_free(address);
|
||||
}
|
||||
[addressLabel setText:displayName];
|
||||
|
||||
|
|
|
|||
|
|
@ -99,7 +99,10 @@
|
|||
|
||||
// Display name
|
||||
if(displayName == nil) {
|
||||
displayName = [NSString stringWithUTF8String:linphone_address_get_username(linphoneAddress)];
|
||||
const char* username = linphone_address_get_username(linphoneAddress);
|
||||
char* address = linphone_address_as_string(linphoneAddress);
|
||||
displayName = [NSString stringWithUTF8String:username?:address];
|
||||
ms_free(address);
|
||||
}
|
||||
[addressLabel setText:displayName];
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue