Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
radkesvat committed Jul 15, 2024
1 parent 602a8c4 commit 47a6450
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 deletions.
10 changes: 5 additions & 5 deletions tunnels/client/http2/helpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,22 +44,22 @@ static void onStreamLineResumed(void *arg)
static void onH2LinePaused(void *arg)
{
http2_client_con_state_t *con = (http2_client_con_state_t *) arg;
// ++(con->pause_counter);
// if (con->pause_counter > 8)
// {
++(con->pause_counter);
if (con->pause_counter > 8)
{
http2_client_child_con_state_t *stream_i;
for (stream_i = con->root.next; stream_i;)
{
pauseLineDownSide(stream_i->line);
stream_i = stream_i->next;
}
// }
}
}

static void onH2LineResumed(void *arg)
{
http2_client_con_state_t *con = (http2_client_con_state_t *) arg;
// con->pause_counter = con->pause_counter > 0 ? (con->pause_counter - 1) : con->pause_counter;
con->pause_counter = con->pause_counter > 0 ? (con->pause_counter - 1) : con->pause_counter;
http2_client_child_con_state_t *stream_i;
for (stream_i = con->root.next; stream_i;)
{
Expand Down
15 changes: 10 additions & 5 deletions tunnels/server/http2/helpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,19 +56,24 @@ static void onStreamLineResumed(void *arg)

static void onH2LinePaused(void *arg)
{
http2_server_con_state_t *con = (http2_server_con_state_t *) arg;
http2_server_child_con_state_t *stream_i;
for (stream_i = con->root.next; stream_i;)
http2_server_con_state_t *con = (http2_server_con_state_t *) arg;
++(con->pause_counter);
if (con->pause_counter > 8)
{
pauseLineUpSide(stream_i->line);
stream_i = stream_i->next;
http2_server_child_con_state_t *stream_i;
for (stream_i = con->root.next; stream_i;)
{
pauseLineUpSide(stream_i->line);
stream_i = stream_i->next;
}
}
}

static void onH2LineResumed(void *arg)
{
http2_server_con_state_t *con = (http2_server_con_state_t *) arg;
http2_server_child_con_state_t *stream_i;
con->pause_counter = con->pause_counter > 0 ? (con->pause_counter - 1) : con->pause_counter;
for (stream_i = con->root.next; stream_i;)
{
resumeLineUpSide(stream_i->line);
Expand Down

0 comments on commit 47a6450

Please sign in to comment.