BookInfoManager: Actually close the document after extraction

DocumentRegistry just decreases a ref, it doesn't close anything.

Plug the same Document leak in a few other places, and document this.
This commit is contained in:
NiLuJe
2021-05-17 22:59:29 +02:00
parent e70bc60f0f
commit 94f708b53b
5 changed files with 10 additions and 6 deletions

View File

@@ -91,6 +91,7 @@ function Document:unlock(password)
end
-- this might be overridden by a document implementation
-- (in which case, do make sure it calls this one, too, to avoid refcounting mismatches in DocumentRegistry!)
function Document:close()
local DocumentRegistry = require("document/documentregistry")
if self.is_open then