diff options
author | Eliot Horowitz <eliot@10gen.com> | 2009-04-21 14:31:30 -0400 |
---|---|---|
committer | Eliot Horowitz <eliot@10gen.com> | 2009-04-21 14:31:30 -0400 |
commit | 77c6ea6148bccc82fba4ead329f1f2428d0577f0 (patch) | |
tree | 579732d2254d9331476df8b18dd82b07fb5c4f8b /s | |
parent | b999749360dcbf19e628ba6052715c0921463f3e (diff) | |
download | mongo-77c6ea6148bccc82fba4ead329f1f2428d0577f0.tar.gz |
Sharding: fix command path MINOR
Diffstat (limited to 's')
-rw-r--r-- | s/strategy_single.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/s/strategy_single.cpp b/s/strategy_single.cpp index 0f53bbd69c4..71c18ce7f35 100644 --- a/s/strategy_single.cpp +++ b/s/strategy_single.cpp @@ -14,10 +14,10 @@ namespace mongo { bool lateAssert = false; - log(3) << "single query: " << q.ns << " " << q.query << endl; - + log(3) << "single query: " << q.ns << " " << q.query << " ntoreturn: " << q.ntoreturn << endl; + try { - if ( q.ntoreturn == 1 && strstr(q.ns, ".$cmd") ) { + if ( ( q.ntoreturn == -1 || q.ntoreturn == 1 ) && strstr(q.ns, ".$cmd") ) { BSONObjBuilder builder; bool ok = runCommandAgainstRegistered(q.ns, q.query, builder); if ( ok ) { |