提交 013096b8 authored 作者: Anthony Minessale's avatar Anthony Minessale

update

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6255 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 c5e0348f
......@@ -68,12 +68,14 @@ SWITCH_DECLARE(int) switch_regex_perform(const char *field, const char *expressi
return 0;
}
if (*expression == '/' && *(expression + (strlen(expression) - 1)) == '/') {
if (*expression == '/') {
char *opts = NULL;
tmp = strdup(expression + 1);
assert(tmp);
if ((opts = strrchr(tmp, '/'))) {
*opts++ = '\0';
} else {
goto end;
}
expression = tmp;
if (opts) {
......@@ -86,6 +88,7 @@ SWITCH_DECLARE(int) switch_regex_perform(const char *field, const char *expressi
}
}
re = pcre_compile(expression, /* the pattern */
flags, /* default options */
&error, /* for error message */
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论