Stop using Event callback return values

Since stock string callback has been deprecated, all event callbacks
return 0.

For compatibility, C declarations are not changed and FFI users are
expected to return 0 from their callbacks.
This commit is contained in:
Alexander Krotov
2019-12-22 00:41:04 +03:00
parent 47be879445
commit 8e0a29e9b5
7 changed files with 73 additions and 130 deletions

View File

@@ -41,7 +41,7 @@ use self::cmdline::*;
// Event Handler
fn receive_event(_context: &Context, event: Event) -> libc::uintptr_t {
fn receive_event(_context: &Context, event: Event) {
match event {
Event::Info(msg) => {
/* do not show the event as this would fill the screen */
@@ -111,8 +111,6 @@ fn receive_event(_context: &Context, event: Event) -> libc::uintptr_t {
print!("\x1b[33m{{Received {:?}}}\n\x1b[0m", event);
}
}
0
}
// Threads for waiting for messages and for jobs