projects
/
haproxy-3.0.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3b7a351
)
MINOR: http_fetch: Add support for empty delim in url_param
author
Martin DOLEZ
<martin@dolez.fr>
Tue, 28 Mar 2023 13:49:53 +0000
(09:49 -0400)
committer
Willy Tarreau
<w@1wt.eu>
Thu, 30 Mar 2023 12:10:59 +0000
(14:10 +0200)
In prevision of adding a third parameter to the url_param
sample-fetch function we need to make the second parameter optional.
User can now pass a empty 2nd argument to keep the default delimiter.
src/http_fetch.c
patch
|
blob
|
history
diff --git
a/src/http_fetch.c
b/src/http_fetch.c
index
f855a67
..
732cfbb
100644
(file)
--- a/
src/http_fetch.c
+++ b/
src/http_fetch.c
@@
-1902,7
+1902,7
@@
static int smp_fetch_url_param(const struct arg *args, struct sample *smp, const
name_len = args->data.str.data;
}
- if (args[1].type)
+ if (args[1].type && *args[1].data.str.area)
delim = *args[1].data.str.area;
if (!smp->ctx.a[0]) { // first call, find the query string