diff options
Diffstat (limited to 'src/mem_pool.cpp')
-rw-r--r-- | src/mem_pool.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/mem_pool.cpp b/src/mem_pool.cpp index 4c2c30d25..74d09d5df 100644 --- a/src/mem_pool.cpp +++ b/src/mem_pool.cpp @@ -9,9 +9,23 @@ #include <botan/libstate.h> #include <botan/util.h> #include <algorithm> +#include <exception> namespace Botan { +namespace { + +/************************************************* +* Memory Allocation Exception * +*************************************************/ +struct Memory_Exhaustion : public std::bad_alloc + { + const char* what() + { return "Ran out of memory, allocation failed"; } + }; + +} + /************************************************* * Memory_Block Constructor * *************************************************/ |