mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-03-03 10:01:27 +00:00
MINOR: htx: Remove the macro IS_HTX_SMP() and always use IS_HTX_STRM() instead
The macro IS_HTX_SMP() is only used at a place, in a context where the stream always exists. So, we can remove it to use IS_HTX_STRM() instead.
This commit is contained in:
parent
b01302f9ac
commit
429b91d308
@ -30,7 +30,6 @@
|
||||
#include <proto/stream.h>
|
||||
|
||||
#define IS_HTX_STRM(strm) ((strm)->flags & SF_HTX)
|
||||
#define IS_HTX_SMP(smp) ((smp)->strm && IS_HTX_STRM((smp)->strm))
|
||||
|
||||
extern struct pool_head *pool_head_uniqueid;
|
||||
|
||||
|
@ -55,7 +55,7 @@ smp_fetch_len(const struct arg *args, struct sample *smp, const char *kw, void *
|
||||
|
||||
chn = ((smp->opt & SMP_OPT_DIR) == SMP_OPT_DIR_RES) ? &smp->strm->res : &smp->strm->req;
|
||||
smp->data.type = SMP_T_SINT;
|
||||
if (IS_HTX_SMP(smp)) {
|
||||
if (IS_HTX_STRM(smp->strm)) {
|
||||
struct htx *htx = htxbuf(&chn->buf);
|
||||
smp->data.u.sint = htx->data - co_data(chn);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user