mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-04-11 03:31:36 +00:00
DEV: coccinelle: Add rule to use chunk_istcat()
instead of chunk_memcat()
This replaces `chunk_memcat()` with `chunk_istcat()` if the parameters are the ist's `.ptr` and `.len`.
This commit is contained in:
parent
2471f5c2b2
commit
755d2419a4
@ -52,6 +52,14 @@ expression e;
|
|||||||
- if (\(i.len\|istlen(i)\) > e) { i.len = e; }
|
- if (\(i.len\|istlen(i)\) > e) { i.len = e; }
|
||||||
+ i = isttrim(i, e);
|
+ i = isttrim(i, e);
|
||||||
|
|
||||||
|
@@
|
||||||
|
struct ist i;
|
||||||
|
struct buffer *b;
|
||||||
|
@@
|
||||||
|
|
||||||
|
- chunk_memcat(b, \(i.ptr\|istptr(i)\) , \(i.len\|istlen(i)\));
|
||||||
|
+ chunk_istcat(b, i);
|
||||||
|
|
||||||
@@
|
@@
|
||||||
struct ist i;
|
struct ist i;
|
||||||
@@
|
@@
|
||||||
|
Loading…
Reference in New Issue
Block a user