From 5a8e994287d8ef181c0a5eac537547d7059b4524 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Sun, 25 Dec 2011 18:43:58 +0100 Subject: mem: add av_max_alloc() to limit the maximum amount that may be allocated in one piece Signed-off-by: Michael Niedermayer --- libavutil/mem.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'libavutil/mem.h') diff --git a/libavutil/mem.h b/libavutil/mem.h index f148c637bb..c6c907ea08 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -176,6 +176,11 @@ static inline int av_size_mult(size_t a, size_t b, size_t *r) return 0; } +/** + * Set the maximum size that may me allocated in one block. + */ +void av_max_alloc(size_t max); + /** * @} */ -- cgit v1.2.3