Skip to content

Commit 68a30e7

Browse files
committed
Close exit_code file handle
1 parent 34b5c2e commit 68a30e7

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

lua/cmake-tools/terminal.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -580,7 +580,9 @@ local get_last_exit_code = function()
580580
print("Could not find last tmp file conaining exit code")
581581
return nil
582582
end
583-
return tonumber(file:read("*n"))
583+
local code = tonumber(file:read("*n"))
584+
file:close()
585+
return code
584586
end
585587

586588
---

0 commit comments

Comments
 (0)