1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-16 17:07:43 +03:00

pg_dump: Rename some typedefs to avoid name conflicts

In struct _archiveHandle, some of the fields have the same name as a
typedef.  This is kind of confusing, so rename the types so they have
names distinct from the struct fields.  In C++, the previous coding
changes the meaning of the typedef in the scope of the struct, causing
warnings and possibly other problems.

Reviewed-by: Andres Freund <andres@anarazel.de>
This commit is contained in:
Peter Eisentraut
2016-08-30 12:00:00 -04:00
parent 20c95f27e7
commit 4be613f692
3 changed files with 55 additions and 55 deletions

View File

@@ -55,7 +55,7 @@ static const char *modulename = gettext_noop("archiver");
static ArchiveHandle *_allocAH(const char *FileSpec, const ArchiveFormat fmt,
const int compression, bool dosync, ArchiveMode mode,
SetupWorkerPtr setupWorkerPtr);
SetupWorkerPtrType setupWorkerPtr);
static void _getObjectDescription(PQExpBuffer buf, TocEntry *te,
ArchiveHandle *AH);
static void _printTocEntry(ArchiveHandle *AH, TocEntry *te, bool isData, bool acl_pass);
@@ -204,7 +204,7 @@ setupRestoreWorker(Archive *AHX)
Archive *
CreateArchive(const char *FileSpec, const ArchiveFormat fmt,
const int compression, bool dosync, ArchiveMode mode,
SetupWorkerPtr setupDumpWorker)
SetupWorkerPtrType setupDumpWorker)
{
ArchiveHandle *AH = _allocAH(FileSpec, fmt, compression, dosync,
@@ -2273,7 +2273,7 @@ _discoverArchiveFormat(ArchiveHandle *AH)
static ArchiveHandle *
_allocAH(const char *FileSpec, const ArchiveFormat fmt,
const int compression, bool dosync, ArchiveMode mode,
SetupWorkerPtr setupWorkerPtr)
SetupWorkerPtrType setupWorkerPtr)
{
ArchiveHandle *AH;
@@ -2446,8 +2446,8 @@ mark_dump_job_done(ArchiveHandle *AH,
void
WriteDataChunksForTocEntry(ArchiveHandle *AH, TocEntry *te)
{
StartDataPtr startPtr;
EndDataPtr endPtr;
StartDataPtrType startPtr;
EndDataPtrType endPtr;
AH->currToc = te;