From cc6990163249cfb2373cd62422191d6c60305f26 Mon Sep 17 00:00:00 2001 From: Eric House Date: Sat, 26 Jan 2013 21:17:46 -0800 Subject: [PATCH] reset to null in loop in case exit due to exceeding retry count --- xwords4/relay/crefmgr.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/xwords4/relay/crefmgr.cpp b/xwords4/relay/crefmgr.cpp index c3441f486..42075d39d 100644 --- a/xwords4/relay/crefmgr.cpp +++ b/xwords4/relay/crefmgr.cpp @@ -413,8 +413,10 @@ CRefMgr::getCookieRef( CookieID cid, bool failOk ) break; } m_cidlock->Relinquish( cinfo, true ); - logf( XW_LOGINFO, "%s: sleeping after failing to get cinfo", __func__ ); + logf( XW_LOGINFO, "%s: (count=%d) sleeping after " + "failing to get cinfo", __func__, count ); usleep(200000); /* 2/10 second */ + cinfo = NULL; } return cinfo; } /* getCookieRef */