Skip to content

Commit

Permalink
solaar: don't close temp file until after CLI call
Browse files Browse the repository at this point in the history
  • Loading branch information
pfps committed Jan 1, 2025
1 parent 62e8aac commit d714be1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/solaar/gtk.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,11 @@ def main():
temp.close()
return
if args.action:
# if any argument, run comandline and exit
result = cli.run(args.action, args.hidraw_path)
# explicit close before return
temp.close()
# if any argument, run comandline and exit
return cli.run(args.action, args.hidraw_path)
return result

gi = _require("gi", "python3-gi (in Ubuntu) or python3-gobject (in Fedora)")
_require("gi.repository.Gtk", "gir1.2-gtk-3.0", gi, "Gtk", "3.0")
Expand Down

0 comments on commit d714be1

Please sign in to comment.