From: Colin Leroy Date: Thu, 8 Oct 2015 16:39:33 +0000 (+0200) Subject: Fix theoretical off-by-one (which should never happen) X-Git-Tag: 3.13.0~22 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=6fcc0e06c5bf6c0a2a49784d54a4e1a5e6a0a5dd;ds=inline Fix theoretical off-by-one (which should never happen) --- diff --git a/src/plugins/notification/notification_pixbuf.c b/src/plugins/notification/notification_pixbuf.c index c14ce2454..22984febe 100644 --- a/src/plugins/notification/notification_pixbuf.c +++ b/src/plugins/notification/notification_pixbuf.c @@ -16,6 +16,7 @@ */ #include "notification_pixbuf.h" +#include "common/utils.h" /* The following files were created from the respective .png or * xpm files with the command @@ -81,6 +82,7 @@ GdkPixbuf* notification_pixbuf_get(NotificationPixbuf wanted) break; } } + cm_return_val_if_fail(wanted < NOTIFICATION_PIXBUF_LAST, NULL); return notification_pixbuf[wanted]; }