]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-index: test-mail-index-write - Fix initializing map.hdr_copy_buf
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Thu, 7 Oct 2021 00:37:29 +0000 (03:37 +0300)
committeraki.tuomi <aki.tuomi@open-xchange.com>
Thu, 7 Oct 2021 07:23:08 +0000 (07:23 +0000)
src/lib-index/test-mail-index-write.c

index 1b95424140ec598a6f3528ac39c6765c4e48364c..88eaa4a07e24904bbf774868a7bcec03c7b53894 100644 (file)
@@ -99,7 +99,7 @@ static void test_mail_index_write(void)
                .hdr_copy_buf = &hdr_copy,
                .rec_map = &rec_map,
        };
-       buffer_create_from_data(&hdr_copy, &map.hdr, sizeof(&map.hdr));
+       buffer_create_from_const_data(&hdr_copy, &map.hdr, sizeof(map.hdr));
        struct mail_index index = {
                .event = event_create(NULL),
                .log = &log,