Build: qualify Alpine/musl test suite (refs #38)

This commit is contained in:
faumaray committed 2026-12-03 17:51:20 +03:00
1 parent 7d25251e21
commit f8c62c9851
2 files changed
+15 -13

No files matched your search

+5 -3
View File
@@ -87,14 +87,16 @@ namespace
std::string recv_until(int fd, std::string_view marker)
{
// Read one byte at a time: the caller reads the body right after the
// header, so consuming bytes past the marker would lose body data.
std::string out;
std::array<char, 1024> buf{};
char c = 0;
while (out.find(marker) == std::string::npos) {
const ssize_t n = ::recv(fd, buf.data(), buf.size(), 0);
const ssize_t n = ::recv(fd, &c, 1, 0);
if (n <= 0) {
break;
}
out.append(buf.data(), static_cast<std::size_t>(n));
out.push_back(c);
if (out.size() > 64 * 1024) {
break;
}