From 5d8cba0f2df937d9e8736edcbadca3588576381a Mon Sep 17 00:00:00 2001 From: Christopher Arndt Date: Sun, 9 Oct 2022 21:05:08 +0200 Subject: [PATCH] fix: cleanup arg default value; signal list --- examples/test_port_connect_cb.nim | 4 ++-- examples/test_port_register.nim | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/test_port_connect_cb.nim b/examples/test_port_connect_cb.nim index b242177..2b96194 100644 --- a/examples/test_port_connect_cb.nim +++ b/examples/test_port_connect_cb.nim @@ -11,7 +11,7 @@ proc errorCb(msg: cstring) {.cdecl.} = # default. Pass ``lvlAll`` when creating the logger to enable them. debug "JACK error: " & $msg -proc cleanup(sig: cint) {.noconv.} = +proc cleanup(sig: cint = 0) {.noconv.} = debug "Cleaning up..." if jclient != nil: @@ -62,4 +62,4 @@ if jclient.activate() == 0: while true: sleep(50) -cleanup() \ No newline at end of file +cleanup() # normally not reached diff --git a/examples/test_port_register.nim b/examples/test_port_register.nim index 1a49885..f9f313d 100644 --- a/examples/test_port_register.nim +++ b/examples/test_port_register.nim @@ -32,7 +32,7 @@ if jclient == nil: when defined(windows): setSignalProc(cleanup, SIGABRT, SIGINT, SIGTERM) else: - setSignalProc(cleanup, SIGHUP, SIGINT, SIGQUIT, SIGTERM) + setSignalProc(cleanup, SIGABRT, SIGHUP, SIGINT, SIGQUIT, SIGTERM) discard jclient.portRegister("in_1", JACK_DEFAULT_AUDIO_TYPE, PortIsInput.ord, 0) discard jclient.portRegister("out_1", JACK_DEFAULT_AUDIO_TYPE, PortIsOutput.ord, 0)