Fix pg_upgrade's pg_scandir_internal() the right way. Backpatch to 9.1.

pull/1/head
Bruce Momjian 14 years ago
parent 988f907d24
commit ee3ef8f30c
  1. 2
      contrib/pg_upgrade/file.c

@ -296,7 +296,7 @@ pg_scandir_internal(const char *dirname,
while ((direntry = readdir(dirdesc)) != NULL)
{
/* Invoke the selector function to see if the direntry matches */
if (selector && (*selector) (direntry))
if (!selector || (*selector) (direntry))
{
count++;

Loading…
Cancel
Save