From: Timo Sirainen Date: Wed, 5 Nov 2008 18:03:05 +0000 (+0200) Subject: dict-file: Minor optimization when writing the file. X-Git-Tag: 1.2.alpha4~101 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=313c43343f711f04a8d4d1f8dd21aaab5c16b2d2;p=thirdparty%2Fdovecot%2Fcore.git dict-file: Minor optimization when writing the file. --HG-- branch : HEAD --- diff --git a/src/lib-dict/dict-file.c b/src/lib-dict/dict-file.c index 78ca849156..aba8a4073b 100644 --- a/src/lib-dict/dict-file.c +++ b/src/lib-dict/dict-file.c @@ -302,6 +302,7 @@ static int file_dict_write_changes(struct file_dict_transaction_context *ctx) file_dict_apply_changes(ctx); output = o_stream_create_fd(fd, 0, FALSE); + o_stream_cork(output); iter = hash_iterate_init(dict->hash); while (hash_iterate(iter, &key, &value)) { o_stream_send_str(output, key);