summaryrefslogtreecommitdiff
path: root/scripting
diff options
context:
space:
mode:
authorAntonin Kral <a.kral@bobek.cz>2011-06-18 21:24:41 +0200
committerAntonin Kral <a.kral@bobek.cz>2011-06-18 21:24:41 +0200
commit64b33ee522375a8dc15be2875dfb7db4502259b0 (patch)
tree44979e0aaf6bb576f4a737a93e071e28809b6779 /scripting
parent4d87ff4aa74d7ae975268ac43eee152dc3f5b7e9 (diff)
downloadmongodb-64b33ee522375a8dc15be2875dfb7db4502259b0.tar.gz
Imported Upstream version 1.8.2
Diffstat (limited to 'scripting')
-rw-r--r--scripting/engine.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripting/engine.cpp b/scripting/engine.cpp
index 60e56ae..f9be639 100644
--- a/scripting/engine.cpp
+++ b/scripting/engine.cpp
@@ -189,12 +189,12 @@ namespace mongo {
set<string> thisTime;
while ( c->more() ) {
- BSONObj o = c->next();
+ BSONObj o = c->nextSafe();
BSONElement n = o["_id"];
BSONElement v = o["value"];
- uassert( 10209 , "name has to be a string" , n.type() == String );
+ uassert( 10209 , str::stream() << "name has to be a string: " << n , n.type() == String );
uassert( 10210 , "value has to be set" , v.type() != EOO );
setElement( n.valuestr() , v );