summaryrefslogtreecommitdiff
path: root/s
diff options
context:
space:
mode:
authorEliot Horowitz <eliot@10gen.com>2009-04-21 14:31:30 -0400
committerEliot Horowitz <eliot@10gen.com>2009-04-21 14:31:30 -0400
commit77c6ea6148bccc82fba4ead329f1f2428d0577f0 (patch)
tree579732d2254d9331476df8b18dd82b07fb5c4f8b /s
parentb999749360dcbf19e628ba6052715c0921463f3e (diff)
downloadmongo-77c6ea6148bccc82fba4ead329f1f2428d0577f0.tar.gz
Sharding: fix command path MINOR
Diffstat (limited to 's')
-rw-r--r--s/strategy_single.cpp6
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 ) {