- 
    Type:Bug 
- 
    Resolution: Done
- 
    Priority:Major - P3 
- 
    Affects Version/s: None
- 
    Component/s: None
- 
    None
- 
        ALL
- 
        None
- 
        None
- 
        None
- 
        None
- 
        None
- 
        None
- 
        None
Currently assumes it is a string without checking. This causes the following commands to treat garbage memory as strings. I haven't been able to crash the server with this, but I do get some odd collection names:
> db.runCommand(
{create:true})
{ "ok" : 1 }> db.runCommand(
{create:null})
{ "ok" : 1 }> db.createCollection() // same as
{create:undefined} { "ok" : 1 }> show tables
Status // from create:true
n(  // from create: null
ped // from createCollection()
see attached one-line patch for an easy fix which gives a helpful message:
> db.createCollection()
{
        "errmsg" : "exception: must pass name of collection to create",
        "code" : 15888,
        "ok" : 0
}