diff options
-rw-r--r-- | db/jsobj.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/db/jsobj.cpp b/db/jsobj.cpp index 9c823dae7f9..530f3f45a6d 100644 --- a/db/jsobj.cpp +++ b/db/jsobj.cpp @@ -540,9 +540,10 @@ namespace mongo { if ( *i != '^' ) return ""; ++i; + // Empty string matches everything, won't limit our search. if ( !*i ) - return 0; + return ""; stringstream ss; for( ; *i; ++i ){ |