fix incorrect parameter
Merge pull request #92 from stef145g/master

Fix memory leaks on db_error by removing hard exit.