pw_rpc: Fix double mutex unlock

The RPC lock was unlocked by both the lock guard and an unlock call.
This replaces the lock guard with a lock call.

Change-Id: I4aea1a4d51c6696ec303ce8d57372d5b70af3c16
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/77304
Pigweed-Auto-Submit: Wyatt Hepler <hepler@google.com>
Reviewed-by: Alexei Frolov <frolv@google.com>
Commit-Queue: Wyatt Hepler <hepler@google.com>
diff --git a/pw_rpc/endpoint.cc b/pw_rpc/endpoint.cc
index 9edec4b..9982ff9 100644
--- a/pw_rpc/endpoint.cc
+++ b/pw_rpc/endpoint.cc
@@ -61,7 +61,7 @@
 }
 
 void Endpoint::RegisterCall(Call& call) {
-  LockGuard lock(rpc_lock());
+  rpc_lock().lock();
 
   Call* const existing_call = FindCallById(
       call.channel_id_locked(), call.service_id(), call.method_id());