From 40c4d6517707cee05fe0f2cfa3efc76bac962f29 Mon Sep 17 00:00:00 2001 From: "Alfred E. Heggestad" Date: Sun, 9 Jul 2017 18:25:41 +0200 Subject: account: added accessor function to AOR --- src/account.c | 6 ++++++ src/ua.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/account.c b/src/account.c index c3f26eb..8f10940 100644 --- a/src/account.c +++ b/src/account.c @@ -520,6 +520,12 @@ enum answermode account_answermode(const struct account *acc) } +const char *account_aor(const struct account *acc) +{ + return acc ? acc->aor : NULL; +} + + /** * Get the authentication username of an account * diff --git a/src/ua.c b/src/ua.c index bceae63..601c4fc 100644 --- a/src/ua.c +++ b/src/ua.c @@ -992,7 +992,7 @@ int ua_options_send(struct ua *ua, const char *uri, */ const char *ua_aor(const struct ua *ua) { - return ua ? ua->acc->aor : NULL; + return ua ? account_aor(ua->acc) : NULL; } -- cgit v1.2.3