From 97d0cee259554f9c028ae9e3bdf77b8617590ffa Mon Sep 17 00:00:00 2001 From: Ian Barwick Date: Tue, 22 May 2018 17:19:55 +0900 Subject: [PATCH] "config_file" is MAXPGPATH, not MAXLEN The two values are the same anyway, so change is more for consistency. --- dbutils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dbutils.c b/dbutils.c index 27bcc187..14c2f9d7 100644 --- a/dbutils.c +++ b/dbutils.c @@ -1734,7 +1734,7 @@ _populate_node_record(PGresult *res, t_node_info *node_info, int row) strncpy(node_info->location, PQgetvalue(res, row, 7), MAXLEN); node_info->priority = atoi(PQgetvalue(res, row, 8)); node_info->active = atobool(PQgetvalue(res, row, 9)); - strncpy(node_info->config_file, PQgetvalue(res, row, 10), MAXLEN); + strncpy(node_info->config_file, PQgetvalue(res, row, 10), MAXPGPATH); /* This won't normally be set */ strncpy(node_info->upstream_node_name, PQgetvalue(res, row, 11), MAXLEN);