Run menubar.utils.parse_dir in protected context

Fixes: https://github.com/awesomeWM/awesome/issues/1761
Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2017-05-01 13:19:19 +02:00
parent 98a43581ba
commit 50cfa6c111
1 changed files with 3 additions and 3 deletions

View File

@ -287,11 +287,11 @@ function utils.parse_dir(dir_path, callback)
enum:async_close() enum:async_close()
end end
gio.Async.start(function() gio.Async.start(protected_call.call)(function()
local result = {} local result = {}
parser(dir_path, result) parser(dir_path, result)
protected_call.call(callback, result) callback(result)
end)() end)
end end
function utils.compute_textbox_width(textbox, s) function utils.compute_textbox_width(textbox, s)