From 092fe4389eb7af3368146f8b23d54d9bec987c52 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Thu, 13 Dec 2012 12:15:23 -0800 Subject: [PATCH] Tiny optimization -- don't find the entry twice. --- src/cpp/ripple/WSHandler.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cpp/ripple/WSHandler.h b/src/cpp/ripple/WSHandler.h index 4d24f6f89..e7ecee3b8 100644 --- a/src/cpp/ripple/WSHandler.h +++ b/src/cpp/ripple/WSHandler.h @@ -100,7 +100,7 @@ public: if (it == mMap.end()) return; ptr = it->second; // prevent the WSConnection from being destroyed until we release the lock - mMap.erase(cpClient); + mMap.erase(it); } }