From 58ca93c123a73b264907a3f6565373e788201392 Mon Sep 17 00:00:00 2001 From: Robert Habermeier Date: Fri, 18 Nov 2016 19:27:32 +0100 Subject: [PATCH] document lock order --- ethcore/src/light/net/mod.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ethcore/src/light/net/mod.rs b/ethcore/src/light/net/mod.rs index 4b92e262e62..2d38d4fd595 100644 --- a/ethcore/src/light/net/mod.rs +++ b/ethcore/src/light/net/mod.rs @@ -170,6 +170,10 @@ pub struct Params { /// This is simply designed for request-response purposes. Higher level uses /// of the protocol, such as synchronization, will function as wrappers around /// this system. +// +// LOCK ORDER: +// Locks must be acquired in the order declared, and when holding a read lock +// on the peers, only one peer may be held at a time. pub struct LightProtocol { provider: Box, genesis_hash: H256,