Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion clickhouse/base/compressed.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,16 @@ CompressedOutput::CompressedOutput(OutputStream * destination, size_t max_compre
}

CompressedOutput::~CompressedOutput() {
Flush();
try
{
Flush();
}
catch (...)
{
// That means we've failed to flush some data e.g. to the socket,
// but there is nothing we can do at this point (can't bring the socket back),
// and throwing in destructor is really a bad idea.
}
}

size_t CompressedOutput::DoWrite(const void* data, size_t len) {
Expand Down