]> git.notmuchmail.org Git - notmuch/commit
CLI/reindex: fix memory leak
authorDavid Bremner <david@tethera.net>
Tue, 16 Apr 2019 01:46:15 +0000 (22:46 -0300)
committerDavid Bremner <david@tethera.net>
Fri, 19 Apr 2019 01:15:44 +0000 (22:15 -0300)
commit08cd2e57bb3de3922ba54ad95c1e8e85a131330c
treebbb4b26a686153c01ce9930c5f8c1be2deeadf18
parent319dd95ebbd841320e269d34e67a824876f8426a
CLI/reindex: fix memory leak

Since message is owned by messages, it was held for the entire run of
the program. This in turn means that the Xapian::Document objects are
not freed, and thus one ends up with (effectively) a copy of one's
entire mailstore in memory when running

       notmuch reindex '*'

Thanks to Olly Betts for the patient help debugging, and the
suggestion of a fix.
notmuch-reindex.c