Skip to content
Snippets Groups Projects
Commit 90a1e4b3 authored by Ludovic Courtès's avatar Ludovic Courtès
Browse files

package: Always clear the SIGINT handler.

* guix/scripts/package.scm (call-with-sigint-handler): Wrap THUNK in
  `dynamic-wind' so that the SIGINT handler is always cleared.
parent 91fe0e20
No related branches found
No related tags found
No related merge requests found
......@@ -295,7 +295,10 @@ (define (call-with-sigint-handler thunk handler)
(lambda (signum)
(sigaction SIGINT SIG_DFL)
(abort-to-prompt %sigint-prompt signum)))
(thunk))
(dynamic-wind
(const #t)
thunk
(cut sigaction SIGINT SIG_DFL)))
(lambda (k signum)
(handler signum))))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment