From 2c1031bd8602f749a81672015811f365a129acff Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter_e@gmx.net>
Date: Tue, 25 Jun 2013 23:50:14 -0400
Subject: [PATCH] pg_receivexlog: Fix logic error

The code checking the WAL file name contained a logic error and wouldn't
actually catch some bad names.
---
 src/bin/pg_basebackup/pg_receivexlog.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/pg_basebackup/pg_receivexlog.c b/src/bin/pg_basebackup/pg_receivexlog.c
index 18507877845..787a3951bda 100644
--- a/src/bin/pg_basebackup/pg_receivexlog.c
+++ b/src/bin/pg_basebackup/pg_receivexlog.c
@@ -145,7 +145,7 @@ FindStreamingStart(uint32 *tli)
 		 * characters.
 		 */
 		if (strlen(dirent->d_name) != 24 ||
-			!strspn(dirent->d_name, "0123456789ABCDEF") == 24)
+			strspn(dirent->d_name, "0123456789ABCDEF") != 24)
 			continue;
 
 		/*
-- 
GitLab