mod_storage_xep0227: Close file handle after reading
authorKim Alvefur <zash@zash.se>
Fri, 15 May 2015 15:17:27 +0200
changeset 6701 95a8aeca1fc9
parent 6700 3d27f5855f4b
child 6702 ccdd0b615106
mod_storage_xep0227: Close file handle after reading
plugins/mod_storage_xep0227.lua
--- a/plugins/mod_storage_xep0227.lua	Fri May 15 15:16:03 2015 +0200
+++ b/plugins/mod_storage_xep0227.lua	Fri May 15 15:17:27 2015 +0200
@@ -17,6 +17,7 @@
 	local f = io_open(path);
 	if not f then return; end
 	local s = f:read("*a");
+	f:close();
 	return parse_xml_real(s);
 end
 local function setXml(user, host, xml)