Module: CZMQ::FFI::Signals
- Defined in:
- lib/czmq-ffi-gen/signals.rb
Overview
This is used to disable CZMQ’s signal handling so blocking calls can be interrupted using Ctrl-C.
Class Method Summary collapse
-
.default_handling_disabled? ⇒ Boolean
Whether the CZMQ’s default signal handling has been disabled.
-
.disable_default_handling ⇒ void
Disables default SIGINT/SIGTERM handling of CZMQ.
Class Method Details
.default_handling_disabled? ⇒ Boolean
Returns whether the CZMQ’s default signal handling has been disabled.
20 21 22 |
# File 'lib/czmq-ffi-gen/signals.rb', line 20 def default_handling_disabled? @default_handling_disabled end |
.disable_default_handling ⇒ void
This method returns an undefined value.
Disables default SIGINT/SIGTERM handling of CZMQ.
13 14 15 16 |
# File 'lib/czmq-ffi-gen/signals.rb', line 13 def disable_default_handling FFI.zsys_handler_set(nil) @default_handling_disabled = true end |