Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit957b90e

Browse files
committed
Fix erroneous error message printout when a configuration file contains
an overlength token. Printout was always garbage and could dump coreentirely :-(. Per report from Martin Pitt.
1 parentc826991 commit957b90e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

‎src/backend/libpq/hba.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/backend/libpq/hba.c,v 1.121 2004/05/19 22:06:16 tgl Exp $
13+
* $PostgreSQL: pgsql/src/backend/libpq/hba.c,v 1.122 2004/05/25 19:11:14 tgl Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -144,14 +144,14 @@ next_token(FILE *fp, char *buf, int bufsz)
144144

145145
if (buf >=end_buf)
146146
{
147+
*buf='\0';
147148
ereport(LOG,
148149
(errcode(ERRCODE_CONFIG_FILE_ERROR),
149150
errmsg("authentication file token too long, skipping: \"%s\"",
150-
buf)));
151+
start_buf)));
151152
/* Discard remainder of line */
152153
while ((c=getc(fp))!=EOF&&c!='\n')
153154
;
154-
buf[0]='\0';
155155
break;
156156
}
157157

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp