]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
dict-file: Minor optimization when writing the file.
authorTimo Sirainen <tss@iki.fi>
Wed, 5 Nov 2008 18:03:05 +0000 (20:03 +0200)
committerTimo Sirainen <tss@iki.fi>
Wed, 5 Nov 2008 18:03:05 +0000 (20:03 +0200)
--HG--
branch : HEAD

src/lib-dict/dict-file.c

index 78ca849156fb7f6d54f676a981a79159ab7a9359..aba8a4073b76a8334933861265eb5c38e951ed83 100644 (file)
@@ -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);