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

Commit06d5803

Browse files
committed
Fix assorted confusion between Oid and int32.
In passing, also make some debugging elog's in pgstat.c a bit moreconsistently worded.Back-patch as far as applicable (9.3 or 9.4; none of these mistakes arereally old).Mark Dilger identified and patched the type violations; the messagerewordings are mine.
1 parent10eb7df commit06d5803

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

‎src/backend/access/heap/tuptoaster.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2155,7 +2155,7 @@ toast_open_indexes(Relation toastrel,
21552155
* wrong if there is nothing.
21562156
*/
21572157
if (!found)
2158-
elog(ERROR,"no valid index found for toast relation with Oid %d",
2158+
elog(ERROR,"no valid index found for toast relation with Oid %u",
21592159
RelationGetRelid(toastrel));
21602160

21612161
returnres;

‎src/backend/postmaster/pgstat.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3600,7 +3600,7 @@ pgstat_write_statsfiles(bool permanent, bool allDbs)
36003600
constchar*statfile=permanent ?PGSTAT_STAT_PERMANENT_FILENAME :pgstat_stat_filename;
36013601
intrc;
36023602

3603-
elog(DEBUG2,"writingstatsfile '%s'",statfile);
3603+
elog(DEBUG2,"writingstats file \"%s\"",statfile);
36043604

36053605
/*
36063606
* Open the statistics temp file to write out the current values.
@@ -3777,7 +3777,7 @@ pgstat_write_db_statsfile(PgStat_StatDBEntry *dbentry, bool permanent)
37773777
get_dbstat_filename(permanent, true,dbid,tmpfile,MAXPGPATH);
37783778
get_dbstat_filename(permanent, false,dbid,statfile,MAXPGPATH);
37793779

3780-
elog(DEBUG2,"writingstatsfile '%s'",statfile);
3780+
elog(DEBUG2,"writingstats file \"%s\"",statfile);
37813781

37823782
/*
37833783
* Open the statistics temp file to write out the current values.
@@ -3858,7 +3858,7 @@ pgstat_write_db_statsfile(PgStat_StatDBEntry *dbentry, bool permanent)
38583858
{
38593859
get_dbstat_filename(false, false,dbid,statfile,MAXPGPATH);
38603860

3861-
elog(DEBUG2,"removing temporarystat file'%s'",statfile);
3861+
elog(DEBUG2,"removing temporarystats file\"%s\"",statfile);
38623862
unlink(statfile);
38633863
}
38643864
}
@@ -4070,7 +4070,7 @@ pgstat_read_statsfiles(Oid onlydb, bool permanent, bool deep)
40704070
/* If requested to read the permanent file, also get rid of it. */
40714071
if (permanent)
40724072
{
4073-
elog(DEBUG2,"removing permanent stats file'%s'",statfile);
4073+
elog(DEBUG2,"removing permanent stats file\"%s\"",statfile);
40744074
unlink(statfile);
40754075
}
40764076

@@ -4228,7 +4228,7 @@ pgstat_read_db_statsfile(Oid databaseid, HTAB *tabhash, HTAB *funchash,
42284228

42294229
if (permanent)
42304230
{
4231-
elog(DEBUG2,"removing permanent stats file'%s'",statfile);
4231+
elog(DEBUG2,"removing permanent stats file\"%s\"",statfile);
42324232
unlink(statfile);
42334233
}
42344234

@@ -4540,7 +4540,7 @@ pgstat_recv_inquiry(PgStat_MsgInquiry *msg, int len)
45404540
DBWriteRequest*newreq;
45414541
PgStat_StatDBEntry*dbentry;
45424542

4543-
elog(DEBUG2,"received inquiry for%d",msg->databaseid);
4543+
elog(DEBUG2,"received inquiry fordatabase %u",msg->databaseid);
45444544

45454545
/*
45464546
* Find the last write request for this DB. If it's older than the
@@ -4598,7 +4598,7 @@ pgstat_recv_inquiry(PgStat_MsgInquiry *msg, int len)
45984598
writetime=pstrdup(timestamptz_to_str(dbentry->stats_timestamp));
45994599
mytime=pstrdup(timestamptz_to_str(cur_ts));
46004600
elog(LOG,
4601-
"stats_timestamp %s is later than collector's time %s fordb %d",
4601+
"stats_timestamp %s is later than collector's time %s fordatabase %u",
46024602
writetime,mytime,dbentry->databaseid);
46034603
pfree(writetime);
46044604
pfree(mytime);
@@ -4770,7 +4770,7 @@ pgstat_recv_dropdb(PgStat_MsgDropdb *msg, int len)
47704770

47714771
get_dbstat_filename(false, false,dbid,statfile,MAXPGPATH);
47724772

4773-
elog(DEBUG2,"removing%s",statfile);
4773+
elog(DEBUG2,"removingstats file \"%s\"",statfile);
47744774
unlink(statfile);
47754775

47764776
if (dbentry->tables!=NULL)

‎src/backend/replication/logical/reorderbuffer.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2458,7 +2458,7 @@ ReorderBufferToastAppendChunk(ReorderBuffer *rb, ReorderBufferTXN *txn,
24582458
Pointerchunk;
24592459
TupleDescdesc=RelationGetDescr(relation);
24602460
Oidchunk_id;
2461-
Oidchunk_seq;
2461+
int32chunk_seq;
24622462

24632463
if (txn->toast_hash==NULL)
24642464
ReorderBufferToastInitHash(rb,txn);

‎src/bin/pg_dump/parallel.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -821,7 +821,7 @@ lockTableNoWait(ArchiveHandle *AH, TocEntry *te)
821821
" pg_class.relname "
822822
" FROM pg_class "
823823
" JOIN pg_namespace on pg_namespace.oid = relnamespace "
824-
" WHERE pg_class.oid = %d",te->catalogId.oid);
824+
" WHERE pg_class.oid = %u",te->catalogId.oid);
825825

826826
res=PQexec(AH->connection,query->data);
827827

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp