From a447ced3d821f0ae202fbf60a2082f54559362c7 Mon Sep 17 00:00:00 2001 From: Kamalesh Babulal Date: Thu, 14 May 2015 11:09:39 +0530 Subject: [PATCH 4/7] src/notify.c: run_notification_tool() - Fix out of bound array indexing Fix out of bound array indexing while forming the command in run_notification_tool(). Signed-off-by: Kamalesh Babulal Cc: Vasant Hegde Signed-off-by: Vasant Hegde --- src/notify.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/notify.c b/src/notify.c index f453397..5b20b64 100644 --- a/src/notify.c +++ b/src/notify.c @@ -498,7 +498,7 @@ run_notification_tool(struct sl_notify *notify, int type, void *records) pos = strchr(cmd, ' '); if (pos) { *pos++ = '\0'; - for (i = 1; i <= 30; i++) { + for (i = 1; i < 30; i++) { if (!pos || !(*pos)) break; while (*pos == ' ') -- 1.9.1