Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit ee3ef8f

Browse files
committed
Fix pg_upgrade's pg_scandir_internal() the right way. Backpatch to 9.1.
1 parent 988f907 commit ee3ef8f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/pg_upgrade/file.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ pg_scandir_internal(const char *dirname,
296296
while ((direntry = readdir(dirdesc)) != NULL)
297297
{
298298
/* Invoke the selector function to see if the direntry matches */
299-
if (selector && (*selector) (direntry))
299+
if (!selector || (*selector) (direntry))
300300
{
301301
count++;
302302

0 commit comments

Comments
 (0)