Improve the error messages in the rlm_redis
authorJorge Pereira <jpereiran@gmail.com>
Wed, 10 Jun 2015 18:02:06 +0000 (15:02 -0300)
committerJorge Pereira <jpereiran@gmail.com>
Wed, 10 Jun 2015 18:02:06 +0000 (15:02 -0300)
src/modules/rlm_redis/rlm_redis.c

index 309c946..3d73869 100644 (file)
@@ -62,6 +62,8 @@ static void *mod_conn_create(TALLOC_CTX *ctx, void *instance)
 
        conn = redisConnect(inst->hostname, inst->port);
        if (conn && conn->err) {
+               ERROR("rlm_redis (%s): Problems with redisConnect('%s', %d), %s",
+                               inst->xlat_name, inst->hostname, inst->port, redisReplyReaderGetError(conn));
                redisFree(conn);
                return NULL;
        }