mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-02-07 14:18:25 +00:00
fix(core): test if cards is null in get_sound_devices_list (crash in no video mode)
This commit is contained in:
parent
b03061b65b
commit
08bff790a6
1 changed files with 5 additions and 3 deletions
|
|
@ -4218,9 +4218,11 @@ bctbx_list_t * linphone_core_get_sound_devices_list(const LinphoneCore *lc){
|
|||
bctbx_list_t * linphone_core_get_video_devices_list(const LinphoneCore *lc){
|
||||
bctbx_list_t *cards_list = NULL;
|
||||
const char** cards = lc->video_conf.cams;
|
||||
for (const char* c = *cards; c; c=*++cards) {
|
||||
cards_list = bctbx_list_append(cards_list, (char *)c);
|
||||
}
|
||||
|
||||
if (cards)
|
||||
for (const char* c = *cards; c; c=*++cards)
|
||||
cards_list = bctbx_list_append(cards_list, (char *)c);
|
||||
|
||||
return cards_list;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue