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

Commit3f6b3be

Browse files
committed
Silence -Wmaybe-uninitialized compiler warnings in dbcommands.c.
When compiling postgres using gcc -O3, there are false-positivewarnings about the now initialized variables. Silence them.Author: Peter Eisentraut, Andres FreundDiscussion:https://postgr.es/m/15fb2350-b8b8-e188-278f-0b34fdee5210@2ndquadrant.com
1 parent5adafaf commit3f6b3be

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

‎src/backend/commands/dbcommands.c

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#include"access/genam.h"
2727
#include"access/heapam.h"
2828
#include"access/htup_details.h"
29+
#include"access/multixact.h"
2930
#include"access/tableam.h"
3031
#include"access/xact.h"
3132
#include"access/xloginsert.h"
@@ -103,14 +104,14 @@ createdb(ParseState *pstate, const CreatedbStmt *stmt)
103104
Relationrel;
104105
Oidsrc_dboid;
105106
Oidsrc_owner;
106-
intsrc_encoding;
107-
char*src_collate;
108-
char*src_ctype;
107+
intsrc_encoding=-1;
108+
char*src_collate=NULL;
109+
char*src_ctype=NULL;
109110
boolsrc_istemplate;
110111
boolsrc_allowconn;
111-
Oidsrc_lastsysoid;
112-
TransactionIdsrc_frozenxid;
113-
MultiXactIdsrc_minmxid;
112+
Oidsrc_lastsysoid=InvalidOid;
113+
TransactionIdsrc_frozenxid=InvalidTransactionId;
114+
MultiXactIdsrc_minmxid=InvalidMultiXactId;
114115
Oidsrc_deftablespace;
115116
volatileOiddst_deftablespace;
116117
Relationpg_database_rel;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp