mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
log: RPC, input, other events
This commit is contained in:
parent
b9bcfa9bc8
commit
7c00b9efca
@ -190,6 +190,9 @@ for i = 1, #functions do
|
|||||||
|
|
||||||
output:write('Object handle_'..fn.name..'(uint64_t channel_id, Array args, Error *error)')
|
output:write('Object handle_'..fn.name..'(uint64_t channel_id, Array args, Error *error)')
|
||||||
output:write('\n{')
|
output:write('\n{')
|
||||||
|
output:write('\n#if MIN_LOG_LEVEL <= DEBUG_LOG_LEVEL')
|
||||||
|
output:write('\n logmsg(DEBUG_LOG_LEVEL, "RPC: ", NULL, -1, true, "invoke '..fn.name..'");')
|
||||||
|
output:write('\n#endif')
|
||||||
output:write('\n Object ret = NIL;')
|
output:write('\n Object ret = NIL;')
|
||||||
-- Declare/initialize variables that will hold converted arguments
|
-- Declare/initialize variables that will hold converted arguments
|
||||||
for j = 1, #fn.parameters do
|
for j = 1, #fn.parameters do
|
||||||
|
@ -358,6 +358,7 @@ static void handle_request(Channel *channel, msgpack_object *request)
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
multiqueue_put(channel->events, on_request_event, 1, evdata);
|
multiqueue_put(channel->events, on_request_event, 1, evdata);
|
||||||
|
DLOG("RPC: scheduled %.*s", method->via.bin.size, method->via.bin.ptr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -351,6 +351,8 @@ static bool input_poll(int ms)
|
|||||||
blocking = true;
|
blocking = true;
|
||||||
multiqueue_process_events(ch_before_blocking_events);
|
multiqueue_process_events(ch_before_blocking_events);
|
||||||
}
|
}
|
||||||
|
DLOG("blocking... events_enabled=%d events_pending=%d", events_enabled,
|
||||||
|
!multiqueue_empty(main_loop.events));
|
||||||
LOOP_PROCESS_EVENTS_UNTIL(&main_loop, NULL, ms, input_ready() || input_eof);
|
LOOP_PROCESS_EVENTS_UNTIL(&main_loop, NULL, ms, input_ready() || input_eof);
|
||||||
blocking = false;
|
blocking = false;
|
||||||
|
|
||||||
|
@ -153,6 +153,7 @@ void mch_exit(int r)
|
|||||||
free_all_mem();
|
free_all_mem();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
ILOG("Nvim exit: %d", r);
|
||||||
exit(r);
|
exit(r);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -64,6 +64,12 @@ getkey:
|
|||||||
may_sync_undo();
|
may_sync_undo();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if MIN_LOG_LEVEL <= DEBUG_LOG_LEVEL
|
||||||
|
char *keyname = key == K_EVENT
|
||||||
|
? "K_EVENT" : (char *)get_special_key_name(key, mod_mask);
|
||||||
|
DLOG("input: %s", keyname);
|
||||||
|
#endif
|
||||||
|
|
||||||
int execute_result = s->execute(s, key);
|
int execute_result = s->execute(s, key);
|
||||||
if (!execute_result) {
|
if (!execute_result) {
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user