aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/backend/libpq/hba.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/backend/libpq/hba.c b/src/backend/libpq/hba.c
index 327a4b42af7..deee05c1979 100644
--- a/src/backend/libpq/hba.c
+++ b/src/backend/libpq/hba.c
@@ -900,8 +900,9 @@ do { \
if (!field) { \
ereport(elevel, \
(errcode(ERRCODE_CONFIG_FILE_ERROR), \
- errmsg("missing entry in file \"%s\" at end of line %d", \
- IdentFileName, line_num))); \
+ errmsg("missing entry at end of line"), \
+ errcontext("line %d of configuration file \"%s\"", \
+ line_num, IdentFileName))); \
*err_msg = psprintf("missing entry at end of line"); \
return NULL; \
} \
@@ -2372,7 +2373,9 @@ parse_ident_line(TokenizedAuthLine *tok_line, int elevel)
ereport(elevel,
(errcode(ERRCODE_INVALID_REGULAR_EXPRESSION),
errmsg("invalid regular expression \"%s\": %s",
- parsedline->ident_user + 1, errstr)));
+ parsedline->ident_user + 1, errstr),
+ errcontext("line %d of configuration file \"%s\"",
+ line_num, IdentFileName)));
*err_msg = psprintf("invalid regular expression \"%s\": %s",
parsedline->ident_user + 1, errstr);