From 18fd79fbb5e98cc8f776e81eb5f075a54411be6f Mon Sep 17 00:00:00 2001 From: Kyotaro Horiguchi Date: Tue, 13 Nov 2018 09:27:48 +0900 Subject: [PATCH 1/1] Fix bogus error handling For somewhat reason set_config_int32_options does bogus error handling. Howerver that error cannot be happen, fixed it. --- pg_hint_plan.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pg_hint_plan.c b/pg_hint_plan.c index 3c99581..8004d6b 100644 --- a/pg_hint_plan.c +++ b/pg_hint_plan.c @@ -2583,8 +2583,7 @@ set_config_int32_option(const char *name, int32 value, GucContext context) if (snprintf(buf, 16, "%d", value) < 0) { ereport(pg_hint_plan_message_level, - (errmsg ("Cannot set integer value: %d: %s", - max_hint_nworkers, strerror(errno)))); + (errmsg ("Failed to convert integer to string: %d", value))); return false; } -- 2.11.0