mariadb_reconnect() tries to reconnect to a server in case the connection died due to timeout or other errors. It uses the same credentials which were specified in mysql_real_connect().
The function will return 0 on sucess.
The function will return an error, if the option MYSQL_OPT_RECONNECT wasn't specified before.