Avoid dependence on stdexcept by throwing a string here, for an internal error that is not supposed ever to be thrown or caught

This commit is contained in:
Chris Cannam
2018-11-29 10:34:43 +00:00
parent d6f55d526e
commit 26c7635c9e

View File

@@ -96,7 +96,7 @@ T *allocate(size_t count)
if (rv) { if (rv) {
#ifndef NO_EXCEPTIONS #ifndef NO_EXCEPTIONS
if (rv == EINVAL) { if (rv == EINVAL) {
throw std::logic_error("Internal error: invalid alignment"); throw "Internal error: invalid alignment";
} else { } else {
throw std::bad_alloc(); throw std::bad_alloc();
} }