RPC CLI: Change ParallelSafe cli command (#793)

Starting RPC session is parallel safe.
Launching application command do lock check inside.
This commit is contained in:
Albert Kharisov 2021-10-27 19:20:08 +04:00 committed by GitHub
parent 732b9546fc
commit 10c65daad7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -438,7 +438,7 @@ void rpc_send_and_release(Rpc* rpc, PB_Main* message) {
#if DEBUG_PRINT
FURI_LOG_I(RPC_TAG, "OUTPUT:");
rpc_print_message(main_message);
rpc_print_message(message);
#endif
bool result = pb_encode_ex(&ostream, &PB_Main_msg, message, PB_ENCODE_DELIMITED);
@ -483,7 +483,7 @@ int32_t rpc_srv(void* p) {
Cli* cli = furi_record_open("cli");
cli_add_command(
cli, "start_rpc_session", CliCommandFlagDefault, rpc_cli_command_start_session, rpc);
cli, "start_rpc_session", CliCommandFlagParallelSafe, rpc_cli_command_start_session, rpc);
while(1) {
pb_istream_t istream = {