amphp / http-client

An advanced async HTTP client library for PHP, enabling efficient, non-blocking, and concurrent requests and responses.
https://amphp.org/http-client
MIT License
707 stars 66 forks source link

END_HEADERS as first packet triggers assertion error #236

Closed nikic closed 4 years ago

nikic commented 4 years ago

Feeding hex2bin("000000010400000000") into the Http2Parser results in an assertion failure:

assert(): assert($this->headerBuffer !== '') failed in .../http-client/src/Connection/Internal/Http2Parser.php on line 316

At least assuming I'm not missing something about error handling conventions here.

kelunik commented 4 years ago

Thanks!