Merge pull request #7 from moai/integration

change -fpic to -fPIC and remove boost -mt since it is no longer relevan...
+ Fix segfault on MongoDB restart (add check for lost connection)
+ Minor makeup
Merge pull request #8 from neoxic/master

Fix segfault on MongoDB restart
+ Add 'query' to db:count()
Changed std:string to std::string in query_where.

It is meant to be a namespace, not a label.
Added db:find_one
added missing test in replicaset.lua.
Stopped a db:find_one assertion from being propagated, instead handle it appropriately and return nil, error.
Merge pull request #11 from mabako/db-find-one

Added db:find_one
Merge pull request #10 from mabako/master

Changed std:string to std::string in query_where.
Merge pull request #9 from neoxic/master

Add 'query' to db:count(ns)
+ Security fixes - don't change key with lua_tostring while traversing
+ Eliminate memory leak
Fixed timeout to be a double, as MongoDB expects, and to ACTUALLY BE USED, since the previous int was shadowing a parameter by the same name
(cherry picked from commit b2cd2eda8e0fbd287544a531dac795c6d2f136f1)
Initialize rw_timeout
(cherry picked from commit b8827d86a7d425fb70370e28ba7b0a51c3ae7c66)
Merge pull request #13 from neoxic/master

Security fixes - don't change key with lua_tostring while traversing tables
Merge pull request #19 from TimMensch/justfix1

Two fixes for luamongo
Added gitignore
Updating for lua 5.2
Minor problem with gridfschunk solved