[dovecot-cvs] dovecot/src/lib-storage/index index-storage.c,1.21,1.22

cras at procontrol.fi cras at procontrol.fi
Sun Dec 22 00:28:09 EET 2002


Update of /home/cvs/dovecot/src/lib-storage/index
In directory danu:/tmp/cvs-serv10230/src/lib-storage/index

Modified Files:
	index-storage.c 
Log Message:
Compile with -Wformat-nonliteral now. Found a format string bug with it :(
But lucky for us, we haven't allowed %n in format strings for a few months
now and those bugs were added after that. So arbitrary code execution
vulnerabilities count is still zero :)



Index: index-storage.c
===================================================================
RCS file: /home/cvs/dovecot/src/lib-storage/index/index-storage.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- index-storage.c	25 Nov 2002 19:02:50 -0000	1.21
+++ index-storage.c	21 Dec 2002 22:28:07 -0000	1.22
@@ -294,14 +294,14 @@
 		mail_storage_set_error(ibox->box.storage, "Out of disk space");
 		break;
 	case MAIL_INDEX_ERROR_INDEX_LOCK_TIMEOUT:
-		mail_storage_set_error(ibox->box.storage, t_strconcat(
-			"Timeout while waiting for lock to index of mailbox ",
-			ibox->box.name, NULL));
+		mail_storage_set_error(ibox->box.storage,
+			"Timeout while waiting for lock to index of mailbox %s",
+			ibox->box.name);
 		break;
 	case MAIL_INDEX_ERROR_MAILBOX_LOCK_TIMEOUT:
-		mail_storage_set_error(ibox->box.storage, t_strconcat(
-			"Timeout while waiting for lock to mailbox ",
-			ibox->box.name, NULL));
+		mail_storage_set_error(ibox->box.storage,
+			"Timeout while waiting for lock to mailbox %s",
+			ibox->box.name);
 		break;
 	}
 
@@ -321,8 +321,8 @@
 	case 1:
 		return TRUE;
 	case 0:
-		mail_storage_set_error(ibox->box.storage, "Maximum number of "
-				       "different custom flags exceeded");
+		mail_storage_set_error(ibox->box.storage,
+			"Maximum number of different custom flags exceeded");
 		return FALSE;
 	default:
 		return mail_storage_set_index_error(ibox);




More information about the dovecot-cvs mailing list