dovecot-1.2: Minor memory allocation tweaks.

dovecot at dovecot.org dovecot at dovecot.org
Wed Oct 28 20:10:55 EET 2009


details:   http://hg.dovecot.org/dovecot-1.2/rev/adee8cb3ff5d
changeset: 9458:adee8cb3ff5d
user:      Timo Sirainen <tss at iki.fi>
date:      Wed Oct 28 14:10:04 2009 -0400
description:
Minor memory allocation tweaks.

diffstat:

2 files changed, 2 insertions(+), 2 deletions(-)
src/lib/failures.c |    2 +-
src/lib/str.c      |    2 +-

diffs (24 lines):

diff -r 778a6418f54b -r adee8cb3ff5d src/lib/failures.c
--- a/src/lib/failures.c	Wed Oct 28 13:51:32 2009 -0400
+++ b/src/lib/failures.c	Wed Oct 28 14:10:04 2009 -0400
@@ -417,7 +417,7 @@ internal_handler(char log_type, const ch
 	T_BEGIN {
 		string_t *str;
 
-		str = t_str_new(512);
+		str = t_str_new(128);
 		str_append_c(str, 1);
 		str_append_c(str, log_type);
 		str_vprintfa(str, format, args);
diff -r 778a6418f54b -r adee8cb3ff5d src/lib/str.c
--- a/src/lib/str.c	Wed Oct 28 13:51:32 2009 -0400
+++ b/src/lib/str.c	Wed Oct 28 14:10:04 2009 -0400
@@ -127,7 +127,7 @@ void str_printfa(string_t *str, const ch
 
 void str_vprintfa(string_t *str, const char *fmt, va_list args)
 {
-#define SNPRINTF_INITIAL_EXTRA_SIZE 256
+#define SNPRINTF_INITIAL_EXTRA_SIZE 128
 	va_list args2;
 	char *tmp;
 	unsigned int init_size;


More information about the dovecot-cvs mailing list