CLEANUP: Use the ist() macro whenever possible
authorTim Duesterhus <tim@bastelstu.be>
Thu, 4 Mar 2021 16:31:47 +0000 (17:31 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 5 Mar 2021 07:28:53 +0000 (08:28 +0100)
commitdcf753aabec42c81a277ed101038ddcad9aec9c3
tree1150f4d97ad443c0ef8126c079c00df32d521273
parentf8b42925609e94c90af0af9dd496e6397363e2d4
CLEANUP: Use the ist() macro whenever possible

Refactoring performed with the following Coccinelle patch:

    @@
    char *s;
    @@

    (
    - ist2(s, strlen(s))
    + ist(s)
    |
    - ist2(strdup(s), strlen(s))
    + ist(strdup(s))
    )

Note that this replacement is safe even in the strdup() case, because `ist()`
will not call `strlen()` on a `NULL` pointer. Instead is inserts a length of
`0`, effectively resulting in `IST_NULL`.
src/check.c
src/fcgi-app.c
src/http_ana.c
src/listener.c
src/mux_fcgi.c
src/mux_h1.c
src/server.c
src/stats.c
src/tcpcheck.c