Skip to content

Commit 20d8235

Browse files
committed
minor comment addressing
1 parent b7febda commit 20d8235

2 files changed

Lines changed: 1 addition & 7 deletions

File tree

include/aws/http/private/h1_stream.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,6 @@ struct aws_h1_stream {
7878
/* List of `struct aws_h1_data_write` which have been moved from synced_data for processing */
7979
struct aws_linked_list pending_data_write_list;
8080

81-
/* Whether the stream is using manual data writes instead of input_stream */
82-
bool using_manual_data_writes : 1;
83-
8481
/* Whether the final data write (with is_end_stream=true) has been received */
8582
bool has_final_data_write : 1;
8683

source/h1_encoder.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1067,7 +1067,6 @@ static int s_encoder_state_data_write_body(struct aws_h1_encoder *encoder, struc
10671067
aws_last_error(),
10681068
aws_error_name(aws_last_error()));
10691069
error_code = aws_last_error();
1070-
aws_h1_data_write_complete_and_destroy(data_write, encoder->current_stream, error_code);
10711070
encoder->message->current_data_write = NULL;
10721071
goto error;
10731072
}
@@ -1077,8 +1076,6 @@ static int s_encoder_state_data_write_body(struct aws_h1_encoder *encoder, struc
10771076
encoder->progress_bytes > encoder->message->content_length) {
10781077
ENCODER_LOGF(
10791078
ERROR, encoder, "Manual data writes exceeded Content-Length: %" PRIu64, encoder->message->content_length);
1080-
aws_h1_data_write_complete_and_destroy(
1081-
data_write, encoder->current_stream, AWS_ERROR_HTTP_OUTGOING_STREAM_LENGTH_INCORRECT);
10821079
encoder->message->current_data_write = NULL;
10831080
error_code = AWS_ERROR_HTTP_OUTGOING_STREAM_LENGTH_INCORRECT;
10841081
goto error;
@@ -1103,7 +1100,6 @@ static int s_encoder_state_data_write_body(struct aws_h1_encoder *encoder, struc
11031100
aws_last_error(),
11041101
aws_error_name(aws_last_error()));
11051102
error_code = aws_last_error();
1106-
aws_h1_data_write_complete_and_destroy(data_write, encoder->current_stream, error_code);
11071103
encoder->message->current_data_write = NULL;
11081104
goto error;
11091105
}
@@ -1138,6 +1134,7 @@ static int s_encoder_state_data_write_body(struct aws_h1_encoder *encoder, struc
11381134
return s_switch_state(encoder, AWS_H1_ENCODER_STATE_DATA_WRITE_NEXT);
11391135

11401136
error:
1137+
aws_h1_data_write_complete_and_destroy(data_write, encoder->current_stream, error_code);
11411138
return aws_raise_error(error_code);
11421139
}
11431140

0 commit comments

Comments
 (0)