Skip to content

Commit c537d98

Browse files
committed
opsie
1 parent 3383a77 commit c537d98

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

packages/bun-uws/src/HttpParser.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -946,12 +946,13 @@ namespace uWS
946946
}
947947

948948
HttpParserResult consumed = fenceAndConsumePostPadded<false>(requireHostHeader,data, length, user, reserved, &req, requestHandler, dataHandler);
949-
if (consumed.returnedData != user) {
949+
if (consumed.httpErrorStatusCode()) {
950950
return consumed;
951951
}
952+
auto consumedBytes = consumed.consumedBytes();
952953

953-
data += consumed.errorStatusCodeOrConsumedBytes;
954-
length -= consumed.errorStatusCodeOrConsumedBytes;
954+
data += consumedBytes;
955+
length -= consumedBytes;
955956

956957
if (length) {
957958
if (length < MAX_FALLBACK_SIZE) {

0 commit comments

Comments
 (0)