fix: define SIGTERM on windows, since it is not exported by system/ansi_c there
Signed-off-by: Christopher Arndt <chris@chrisarndt.de>
This commit is contained in:
parent
3b40310afd
commit
2c99d183ba
|
@ -1,13 +1,15 @@
|
||||||
import system/ansi_c
|
import system/ansi_c
|
||||||
|
|
||||||
export SIG_DFL, SIGABRT, SIGFPE, SIGILL, SIGINT, SIGSEGV, SIGTERM
|
export SIG_DFL, SIGABRT, SIGFPE, SIGILL, SIGINT, SIGSEGV
|
||||||
|
|
||||||
when not defined(windows):
|
when not defined(windows):
|
||||||
export SIGPIPE
|
export SIGPIPE, SIGTERM
|
||||||
var
|
var
|
||||||
SIG_IGN* {.importc: "SIG_IGN", header: "<signal.h>".}: cint
|
SIG_IGN* {.importc: "SIG_IGN", header: "<signal.h>".}: cint
|
||||||
SIGHUP* {.importc: "SIGHUP", header: "<signal.h>".}: cint
|
SIGHUP* {.importc: "SIGHUP", header: "<signal.h>".}: cint
|
||||||
SIGQUIT* {.importc: "SIGQUIT", header: "<signal.h>".}: cint
|
SIGQUIT* {.importc: "SIGQUIT", header: "<signal.h>".}: cint
|
||||||
|
else:
|
||||||
|
const SIGTERM* = cint(15)
|
||||||
|
|
||||||
type CSighandlerT = proc (a: cint) {.noconv.}
|
type CSighandlerT = proc (a: cint) {.noconv.}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue