We set the producers in a flow chain specifically rather than using a tunnel level variable in order to handle bi-directional tunnels correctly. In such a case the flow control on producers is not related so a single value for the tunnel won't work. */
| 538 | not related so a single value for the tunnel won't work. |
| 539 | */ |
| 540 | void |
| 541 | HttpTunnelProducer::set_throttle_src(HttpTunnelProducer *srcp) |
| 542 | { |
| 543 | HttpTunnelProducer *p = this; |
| 544 | p->flow_control_source = srcp; |
| 545 | for (HttpTunnelConsumer *c = consumer_list.head; c; c = c->link.next) { |
| 546 | if (!c->is_sink()) { |
| 547 | p = c->self_producer; |
| 548 | if (p) { |
| 549 | p->set_throttle_src(srcp); |
| 550 | } |
| 551 | } |
| 552 | } |
| 553 | } |
| 554 | |
| 555 | HttpTunnelConsumer::HttpTunnelConsumer() : link() {} |
| 556 |
no test coverage detected