/* attempt to extract the endpoint name */
if ((aor_uri = strchr(name, '/'))) {
- /* format was 'endpoint/' */
+ /* format was 'endpoint/(aor_name | uri)' */
*aor_uri++ = '\0';
} else if ((aor_uri = strchr(name, '@'))) {
- /* format was 'endpoint@' - don't use the rest */
+ /* format was 'endpoint@domain' - discard the domain */
*aor_uri = '\0';
+
+ /*
+ * We may want to match without any user options getting
+ * in the way.
+ */
+ AST_SIP_USER_OPTIONS_TRUNCATE_CHECK(name);
}
/* at this point, if name is not empty then it
ast_msg_destroy(mdata->msg);
}
-static struct msg_data* msg_data_create(const struct ast_msg *msg, const char *to, const char *from)
+static struct msg_data *msg_data_create(const struct ast_msg *msg, const char *to, const char *from)
{
- char *tag;
+ char *uri_params;
struct msg_data *mdata = ao2_alloc(sizeof(*mdata), msg_data_destroy);
if (!mdata) {