1
0
Fork 0
mirror of https://gitlab.gnome.org/GNOME/calls.git synced 2024-06-28 14:49:30 +00:00

sip: Allow controlling automatic account loading via environment

This commit is contained in:
Evangelos Ribeiro Tzaras 2021-04-05 02:33:31 +02:00
parent 0b73103384
commit 75d32d0924
2 changed files with 5 additions and 3 deletions

View file

@ -322,10 +322,11 @@ calls_sip_provider_constructed (GObject *object)
CallsSipProvider *self = CALLS_SIP_PROVIDER (object);
g_autoptr (GError) error = NULL;
gboolean auto_load_accounts = TRUE;
const gchar *env_do_not_auto_load;
#ifdef FOR_TESTING
auto_load_accounts = FALSE;
#endif
env_do_not_auto_load = g_getenv ("CALLS_SIP_DO_NOT_AUTOLOAD");
if (env_do_not_auto_load && env_do_not_auto_load[0] != '\0')
auto_load_accounts = FALSE;
if (calls_sip_provider_init_sofia (self, &error)) {
if (auto_load_accounts)

View file

@ -8,6 +8,7 @@ test_env = [
'PYTHONDONTWRITEBYTECODE=yes',
'MALLOC_CHECK_=2',
'NO_AT_BRIDGE=1',
'CALLS_SIP_DO_NOT_AUTOLOAD=1',
]
test_cflags = [