From d8331c811a46355338cb6593b0ba532ad5e457f4 Mon Sep 17 00:00:00 2001
From: Stephan Bosch <stephan@rename-it.nl>
Date: Sun, 21 Aug 2016 11:28:32 +0200
Subject: [PATCH] lib-sieve: vacation extension: Fixed invalid evaluation of
 the mail_get_headers() return value.

Found with clang -Wstrict-bool.
---
 src/lib-sieve/plugins/vacation/cmd-vacation.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib-sieve/plugins/vacation/cmd-vacation.c b/src/lib-sieve/plugins/vacation/cmd-vacation.c
index 57d2d9ab8..de31cff88 100644
--- a/src/lib-sieve/plugins/vacation/cmd-vacation.c
+++ b/src/lib-sieve/plugins/vacation/cmd-vacation.c
@@ -961,7 +961,7 @@ static int act_vacation_send
 	/* Compose proper in-reply-to and references headers */
 
 	if ( mail_get_headers
-		(msgdata->mail, "references", &headers) ) {
+		(msgdata->mail, "references", &headers) < 0 ) {
 		return sieve_result_mail_error(aenv, msgdata->mail,
 			"vacation action: "
 			"failed to read header field `references'");
-- 
GitLab