mirror of
https://github.com/audacity/linuxdeploy.git
synced 2026-04-17 08:32:53 -05:00
Don't use exceptions to detect abnormal behavior
https://isocpp.org/wiki/faq/exceptions#why-not-exceptions
This commit is contained in:
@@ -34,8 +34,7 @@ namespace linuxdeploy {
|
||||
if (size == 0)
|
||||
continue;
|
||||
|
||||
if (size > buf.size())
|
||||
throw std::runtime_error("Read more bytes than buffer size");
|
||||
assert(size <= buf.size());
|
||||
|
||||
auto outBufSize = outBuf.size();
|
||||
outBuf.reserve(outBufSize + size + 1);
|
||||
|
||||
Reference in New Issue
Block a user