mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-15 22:38:08 +00:00
Revert tilghman and pari's code changes, as
we do NOT need to uri_decode in manager. (if I sent core%20show%20channels from a telnet session, it should be interpreted literally, however, if I send that from an http session, it should be decoded, which is the behaivor now) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@133770 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -1270,8 +1270,7 @@ static enum error_type handle_updates(struct mansession *s, const struct message
|
|||||||
{
|
{
|
||||||
int x;
|
int x;
|
||||||
char hdr[40];
|
char hdr[40];
|
||||||
const char *action, *cat, *match, *line, *tmp;
|
const char *action, *cat, *var, *value, *match, *line;
|
||||||
char *var, *value;
|
|
||||||
struct ast_category *category;
|
struct ast_category *category;
|
||||||
struct ast_variable *v;
|
struct ast_variable *v;
|
||||||
struct ast_str *str1 = ast_str_create(16), *str2 = ast_str_create(16);
|
struct ast_str *str1 = ast_str_create(16), *str2 = ast_str_create(16);
|
||||||
@@ -1287,23 +1286,10 @@ static enum error_type handle_updates(struct mansession *s, const struct message
|
|||||||
snprintf(hdr, sizeof(hdr), "Cat-%06d", x);
|
snprintf(hdr, sizeof(hdr), "Cat-%06d", x);
|
||||||
cat = astman_get_header(m, hdr);
|
cat = astman_get_header(m, hdr);
|
||||||
snprintf(hdr, sizeof(hdr), "Var-%06d", x);
|
snprintf(hdr, sizeof(hdr), "Var-%06d", x);
|
||||||
if ((tmp = astman_get_header(m, hdr))) {
|
var = astman_get_header(m, hdr);
|
||||||
ast_str_make_space(&str1, strlen(tmp) + 1);
|
|
||||||
strcpy(str1->str, tmp);
|
|
||||||
var = str1->str;
|
|
||||||
ast_uri_decode(var);
|
|
||||||
} else {
|
|
||||||
var = "";
|
|
||||||
}
|
|
||||||
snprintf(hdr, sizeof(hdr), "Value-%06d", x);
|
snprintf(hdr, sizeof(hdr), "Value-%06d", x);
|
||||||
if ((tmp = astman_get_header(m, hdr))) {
|
value = astman_get_header(m, hdr);
|
||||||
ast_str_make_space(&str2, strlen(tmp) + 1);
|
|
||||||
strcpy(str2->str, tmp);
|
|
||||||
value = str2->str;
|
|
||||||
ast_uri_decode(value);
|
|
||||||
} else {
|
|
||||||
value = "";
|
|
||||||
}
|
|
||||||
if (!ast_strlen_zero(value) && *value == '>') {
|
if (!ast_strlen_zero(value) && *value == '>') {
|
||||||
object = 1;
|
object = 1;
|
||||||
value++;
|
value++;
|
||||||
|
|||||||
Reference in New Issue
Block a user