"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/flt_http_comp.c" between
haproxy-2.0.13.tar.gz and haproxy-2.0.14.tar.gz

About: HAProxy is a TCP/HTTP reverse proxy which is particularly suited for high availability environments. LTS (Long-Term Support) release.

flt_http_comp.c  (haproxy-2.0.13):flt_http_comp.c  (haproxy-2.0.14)
skipping to change at line 204 skipping to change at line 204
end: end:
return 1; return 1;
} }
static int static int
comp_http_payload(struct stream *s, struct filter *filter, struct http_msg *msg, comp_http_payload(struct stream *s, struct filter *filter, struct http_msg *msg,
unsigned int offset, unsigned int len) unsigned int offset, unsigned int len)
{ {
struct comp_state *st = filter->ctx; struct comp_state *st = filter->ctx;
struct htx *htx = htxbuf(&msg->chn->buf); struct htx *htx = htxbuf(&msg->chn->buf);
struct htx_ret htxret = htx_find_offset(htx, offset);
struct htx_blk *blk; struct htx_blk *blk;
int ret, consumed = 0, to_forward = 0; int ret, consumed = 0, to_forward = 0;
for (blk = htx_get_first_blk(htx); blk && len; blk = htx_get_next_blk(htx blk = htxret.blk;
, blk)) { offset = htxret.ret;
for (; blk && len; blk = htx_get_next_blk(htx, blk)) {
enum htx_blk_type type = htx_get_blk_type(blk); enum htx_blk_type type = htx_get_blk_type(blk);
uint32_t sz = htx_get_blksz(blk); uint32_t sz = htx_get_blksz(blk);
struct ist v; struct ist v;
if (offset >= sz) {
offset -= sz;
continue;
}
switch (type) { switch (type) {
case HTX_BLK_UNUSED: case HTX_BLK_UNUSED:
break; break;
case HTX_BLK_DATA: case HTX_BLK_DATA:
v = htx_get_blk_value(htx, blk); v = htx_get_blk_value(htx, blk);
v.ptr += offset; v.ptr += offset;
v.len -= offset; v.len -= offset;
if (v.len > len) if (v.len > len)
v.len = len; v.len = len;
 End of changes. 3 change blocks. 
7 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)