Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 14570c2

Browse files
committed
Remove superflous variable from xlogreader's XLogFindNextRecord().
Pointed out by Coverity. Since this is mere, and debatable, cosmetics I'm not backpatching this.
1 parent 58bc474 commit 14570c2

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/backend/access/transam/xlogreader.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -833,7 +833,6 @@ XLogFindNextRecord(XLogReaderState *state, XLogRecPtr RecPtr)
833833
XLogRecPtr found = InvalidXLogRecPtr;
834834
uint32 pageHeaderSize;
835835
XLogPageHeader header;
836-
XLogRecord *record;
837836
int readLen;
838837
char *errormsg;
839838

@@ -875,7 +874,7 @@ XLogFindNextRecord(XLogReaderState *state, XLogRecPtr RecPtr)
875874
* because either we're at the first record after the beginning of a page
876875
* or we just jumped over the remaining data of a continuation.
877876
*/
878-
while ((record = XLogReadRecord(state, tmpRecPtr, &errormsg)))
877+
while (XLogReadRecord(state, tmpRecPtr, &errormsg) != NULL)
879878
{
880879
/* continue after the record */
881880
tmpRecPtr = InvalidXLogRecPtr;

0 commit comments

Comments
 (0)