1010 *
1111 *
1212 * IDENTIFICATION
13- * $PostgreSQL: pgsql/src/backend/libpq/hba.c,v 1.183 2009/03/07 21:28:00 mha Exp $
13+ * $PostgreSQL: pgsql/src/backend/libpq/hba.c,v 1.184 2009/03/25 14:12:02 petere Exp $
1414 *
1515 *-------------------------------------------------------------------------
1616 */
@@ -578,7 +578,7 @@ check_db(const char *dbname, const char *role, char *param_str)
578578#define INVALID_AUTH_OPTION (optname ,validmethods ) do {\
579579ereport(LOG, \
580580(errcode(ERRCODE_CONFIG_FILE_ERROR), \
581- errmsg("authentication option'%s' is only valid for authentication methods'%s' ", \
581+ errmsg("authentication option\"%s\" is only valid for authentication methods\"%s\" ", \
582582optname, validmethods), \
583583 errcontext("line %d of configuration file \"%s\"", \
584584line_num, HbaFileName))); \
@@ -594,7 +594,7 @@ check_db(const char *dbname, const char *role, char *param_str)
594594if (argvar == NULL) {\
595595ereport(LOG, \
596596(errcode(ERRCODE_CONFIG_FILE_ERROR), \
597- errmsg("authentication method'%s' requires argument'%s' to be set", \
597+ errmsg("authentication method\"%s\" requires argument\"%s\" to be set", \
598598authname, argname), \
599599 errcontext("line %d of configuration file \"%s\"", \
600600line_num, HbaFileName))); \
@@ -1024,7 +1024,7 @@ parse_hba_line(List *line, int line_num, HbaLine *parsedline)
10241024{
10251025ereport (LOG ,
10261026(errcode (ERRCODE_CONFIG_FILE_ERROR ),
1027- errmsg ("invalidldap port'%s' " ,c ),
1027+ errmsg ("invalidLDAP portnumber: \"%s\" " ,c ),
10281028errcontext ("line %d of configuration file \"%s\"" ,
10291029line_num ,HbaFileName )));
10301030return false;
@@ -1068,7 +1068,7 @@ parse_hba_line(List *line, int line_num, HbaLine *parsedline)
10681068{
10691069ereport (LOG ,
10701070(errcode (ERRCODE_CONFIG_FILE_ERROR ),
1071- errmsg ("unknown authentication option name '%s' " ,token ),
1071+ errmsg ("unknown authentication option name: \"%s\" " ,token ),
10721072errcontext ("line %d of configuration file \"%s\"" ,
10731073line_num ,HbaFileName )));
10741074return false;
@@ -1488,7 +1488,7 @@ parse_ident_usermap(List *line, int line_number, const char *usermap_name,
14881488pg_regerror (r ,& re ,errstr ,sizeof (errstr ));
14891489ereport (ERROR ,
14901490(errcode (ERRCODE_INVALID_REGULAR_EXPRESSION ),
1491- errmsg ("invalid regular expression'%s' : %s" ,file_ident_user + 1 ,errstr )));
1491+ errmsg ("invalid regular expression\"%s\" : %s" ,file_ident_user + 1 ,errstr )));
14921492
14931493pfree (wstr );
14941494* error_p = true;
@@ -1510,7 +1510,7 @@ parse_ident_usermap(List *line, int line_number, const char *usermap_name,
15101510pg_regerror (r ,& re ,errstr ,sizeof (errstr ));
15111511ereport (ERROR ,
15121512(errcode (ERRCODE_INVALID_REGULAR_EXPRESSION ),
1513- errmsg ("regular expression match for'%s' failed: %s" ,file_ident_user + 1 ,errstr )));
1513+ errmsg ("regular expression match for\"%s\" failed: %s" ,file_ident_user + 1 ,errstr )));
15141514* error_p = true;
15151515}
15161516
@@ -1526,7 +1526,7 @@ parse_ident_usermap(List *line, int line_number, const char *usermap_name,
15261526if (matches [1 ].rm_so < 0 )
15271527ereport (ERROR ,
15281528(errcode (ERRCODE_INVALID_REGULAR_EXPRESSION ),
1529- errmsg ("regular expression'%s' has no subexpressions as requested by backreference in'%s' " ,
1529+ errmsg ("regular expression\"%s\" has no subexpressions as requested by backreference in\"%s\" " ,
15301530file_ident_user + 1 ,file_pgrole )));
15311531/* length: original length minus length of \1 plus length of match plus null terminator */
15321532regexp_pgrole = palloc0 (strlen (file_pgrole )- 2 + (matches [1 ].rm_eo - matches [1 ].rm_so )+ 1 );
@@ -1642,9 +1642,9 @@ check_usermap(const char *usermap_name,
16421642if (!found_entry && !error )
16431643{
16441644ereport (LOG ,
1645- (errmsg ("no match in usermap for user'%s' authenticated as'%s' " ,
1645+ (errmsg ("no match in usermap for user\"%s\" authenticated as\"%s\" " ,
16461646pg_role ,auth_user ),
1647- errcontext ("usermap'%s' " ,usermap_name )));
1647+ errcontext ("usermap\"%s\" " ,usermap_name )));
16481648}
16491649return found_entry ?STATUS_OK :STATUS_ERROR ;
16501650}