vquic: make vquic_send_packets not return without setting psent

This is debug code, but since the caller might use the value even when
this function returns error, it needs to be cleared properly here.

Spotted by Clang-tidy

Closes #15807
This commit is contained in:
Daniel Stenberg 2024-12-23 00:01:12 +01:00
parent 3f041a3852
commit 5bdcaa76d1
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -248,6 +248,7 @@ static CURLcode vquic_send_packets(struct Curl_cfilter *cf,
/* simulate network blocking/partial writes */
if(qctx->wblock_percent > 0) {
unsigned char c;
*psent = 0;
Curl_rand(data, &c, 1);
if(c >= ((100-qctx->wblock_percent)*256/100)) {
CURL_TRC_CF(data, cf, "vquic_flush() simulate EWOULDBLOCK");