]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
liblib: Don't segfault if write is attempted beyond non-dynamic buffer's bounds.
authorTimo Sirainen <tss@iki.fi>
Mon, 23 Aug 2010 17:43:17 +0000 (18:43 +0100)
committerTimo Sirainen <tss@iki.fi>
Mon, 23 Aug 2010 17:43:17 +0000 (18:43 +0100)
src/lib/buffer.c

index b92837e76711f3a0d1b6181cc478cd959052a511..2c93f680404e2a574686a6e45d24d30bc4019e4a 100644 (file)
@@ -57,6 +57,7 @@ buffer_check_limits(struct real_buffer *buf, size_t pos, size_t data_size)
                if (unlikely(!buf->dynamic)) {
                        i_panic("Buffer full (%"PRIuSIZE_T" > %"PRIuSIZE_T", "
                                "pool %s)", pos + data_size, buf->alloc,
+                               buf->pool == NULL ? "<none>" :
                                pool_get_name(buf->pool));
                }