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

Commite158bbb

Browse files
committed
Free PQresult on error in pg_receivexlog.
The leak is fairly small and rare, but a leak nevertheless.Per Coverity report. Backpatch to 9.2, where pg_receivexlog was added.pg_basebackup shares the code, but it always exits on error, so there isno real leak.
1 parent9bc1b43 commite158bbb

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

‎src/bin/pg_basebackup/receivelog.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -612,6 +612,7 @@ ReceiveXlogStream(PGconn *conn, XLogRecPtr startpos, uint32 timeline,
612612
fprintf(stderr,
613613
_("%s: unexpected termination of replication stream: %s"),
614614
progname,PQresultErrorMessage(res));
615+
PQclear(res);
615616
gotoerror;
616617
}
617618
PQclear(res);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp