From b5a86240a916697c5e4b4a93cf6b774584589893 Mon Sep 17 00:00:00 2001 From: Dwight Date: Wed, 14 Oct 2009 11:01:29 -0400 Subject: [PATCH] comment minor --- db/repl.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/db/repl.cpp b/db/repl.cpp index 94d06979722..a78f8663656 100644 --- a/db/repl.cpp +++ b/db/repl.cpp @@ -1210,14 +1210,10 @@ namespace mongo { { time_t saveLast = time(0); while ( 1 ) { - /* TODO: WHY is c->more() called twice here? Once in this block it's clearly false? - Also: isn't it bad to call more() without a temprelease? seems like we need - another helper haveMoreWithoutRequesting(), and then if that is false, we temp - release and try more(). - */ + /* todo this code is ugly and confusing fix */ if ( !c->more() ) { dblock lk; - OpTime nextLastSaved = nextLastSavedLocalTs(); + OpTime nextLastSaved = nextLastSavedLocalTs(); // this may make c->more() become true { dbtemprelease t; if ( c->more() ) {