Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6178f3c

Browse files
committed
pg_dump: Fix dumping of WITH OIDS tables
A table with OIDs that was the first in the dump output would not getdumped with OIDs enabled. Fix that.The reason was that the currWithOids flag was declared to be bool butactually also takes a -1 value for "don't know yet". But understdbool.h semantics, that is coerced to true, so the required SETdefault_with_oids command is not output again. Change the variabletype to char to fix that.Reported-by: Derek Nelson <derek@pipelinedb.com>
1 parentb59d4d6 commit6178f3c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

‎src/bin/pg_dump/pg_backup_archiver.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,8 @@ struct _archiveHandle
347347
char*currUser;/* current username, or NULL if unknown */
348348
char*currSchema;/* current schema, or NULL */
349349
char*currTablespace;/* current tablespace, or NULL */
350-
boolcurrWithOids;/* current default_with_oids setting */
350+
charcurrWithOids;/* current default_with_oids setting: true,
351+
* false, or -1 for unknown, forcing a SET */
351352

352353
void*lo_buf;
353354
size_tlo_buf_used;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp