Fix memory leaks setting error documents on exceptions

If the error documents in php_mongo_trigger_error_on_command_failure() and php_mongo_trigger_error_on_gle() happen to be a return_value (thanks to MONGO_METHOD macros), memory leaks are possible. A work-around is to copy the array into a new zval before assigning it to the exception.