Details
-
Bug
-
Resolution: Done
-
Trivial - P5
-
None
-
None
-
ALL
Description
see str.match() lines below - bad with certain collection names
> db.foo.validate
|
function () {
|
var res = this._db.runCommand(
|
|
|
{validate:this.getName()}
|
|
|
);
|
res.valid = false;
|
var raw = res.result || res.raw;
|
if (raw) {
|
var str = "-" + tojson(raw);
|
res.valid = !(str.match(/exception/) || str.match(/corrupt/));
|
var p = /lastExtentSize:(\d+)/;
|
var r = p.exec(str);
|
if (r)
|
|
|
{ res.lastExtentSize = Number(r[1]); }
|
|
|
}
|
return res;
|
}>
|
|