From 3c8dee0ba7c937a4fa092be533de25de0951dd5e Mon Sep 17 00:00:00 2001 From: Solderpunk Date: Fri, 14 Dec 2018 10:51:03 +0000 Subject: Permit graceful cancellation of thread saving. --- telem.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/telem.lua b/telem.lua index 5a99e87..9b81881 100755 --- a/telem.lua +++ b/telem.lua @@ -440,6 +440,10 @@ end function do_type_save() io.write("Save thread to file: ") local filename = io.read() + if string.len(filename) == 0 then + print("Saving cancelled.") + return + end local ret, err = do_type_savefile(filename) if ret == nil then print(err) end end -- cgit v1.2.3