Make use of xlog_internal.h's macros in WAL-related utilities.

Fujii Masao <fujii@postgresql.org>

Commit: 163e29dc380137127cf7e9c23b1596b78ad0ce81
Author: Fujii Masao <fujii@postgresql.org>
Date: 2015-07-02T01:36:18Z
Releases: 9.5.0
Make use of xlog_internal.h's macros in WAL-related utilities.

Commit 179cdd09 added macros to check if a filename is a WAL segment
or other such file. However there were still some instances of the
strlen + strspn combination to check for that in WAL-related utilities
like pg_archivecleanup. Those checks can be replaced with the macros.

This patch makes use of the macros in those utilities and
which would make the code a bit easier to read.

Back-patch to 9.5.

Michael Paquier

Files