Skip to content

Commit fb32615

Browse files
committed
Merge branch 'PGPROEE9_6' into PGPROEE9_6_sha2_scram_port_v3_task_CORE-416
2 parents 80eb03d + a8358e5 commit fb32615

File tree

7 files changed

+27
-14
lines changed

7 files changed

+27
-14
lines changed

contrib/pgpro_scheduler/src/cron_string.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,11 @@ typedef struct {
4141
} cron_ent_t;
4242

4343
void destroyCronEnt(cron_ent_t *);
44-
void _cps_set_error(int num, const char *message, ...) __attribute__ ((format (gnu_printf, 2, 3)));;
44+
void _cps_set_error(int num, const char *message, ...)
45+
#ifdef __GNUC__
46+
__attribute__ ((format (gnu_printf, 2, 3)))
47+
#endif
48+
;;
4549
char *get_cps_error(void);
4650
int _cps_string_has(char *str, char c);
4751
char *_cps_append_string(char *str, char *to_add);

contrib/pgpro_scheduler/src/scheduler_job.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,11 @@ typedef struct {
3030
job_t *init_scheduler_job(job_t *j);
3131
job_t *get_expired_jobs(char *nodename, int *n, int *is_error);
3232
job_t *get_jobs_to_do(char *nodename, int *n, int *is_error);
33-
job_t *set_job_error(job_t *j, const char *fmt, ...) __attribute__ ((format (gnu_printf, 2, 3)));;
33+
job_t *set_job_error(job_t *j, const char *fmt, ...)
34+
#ifdef __GNUC__
35+
__attribute__ ((format (gnu_printf, 2, 3)));
36+
#endif
37+
;
3438
int move_job_to_log(job_t *j, bool status);
3539
void destroy_job(job_t *j, int selfdestroy);
3640

contrib/rum/src/rum.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -495,7 +495,7 @@ extern void rumPrepareEntryScan(RumBtree btree, OffsetNumber attnum,
495495
RumState * rumstate);
496496
extern void rumEntryFillRoot(RumBtree btree, Buffer root, Buffer lbuf, Buffer rbuf,
497497
Page page, Page lpage, Page rpage);
498-
extern IndexTuple rumPageGetLinkItup(Buffer buf, Page page);
498+
extern IndexTuple rumPageGetLinkItup(RumBtree btree, Buffer buf, Page page);
499499
extern void rumReadTuple(RumState * rumstate, OffsetNumber attnum,
500500
IndexTuple itup, RumKey * items);
501501
extern void rumReadTuplePointers(RumState * rumstate, OffsetNumber attnum,

contrib/rum/src/rumentrypage.c

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ rumReadTuplePointers(RumState * rumstate, OffsetNumber attnum,
6565
* block number is inserted into t_tid.
6666
*/
6767
static IndexTuple
68-
RumFormInteriorTuple(IndexTuple itup, Page page, BlockNumber childblk)
68+
RumFormInteriorTuple(RumBtree btree, IndexTuple itup, Page page,
69+
BlockNumber childblk)
6970
{
7071
IndexTuple nitup;
7172
RumNullCategory category;
@@ -92,10 +93,10 @@ RumFormInteriorTuple(IndexTuple itup, Page page, BlockNumber childblk)
9293
/* Now insert the correct downlink */
9394
RumSetDownlink(nitup, childblk);
9495

95-
category = RumGetNullCategory(itup);
96-
if (category == RUM_CAT_NULL_KEY || category == RUM_CAT_EMPTY_ITEM ||
97-
category == RUM_CAT_NULL_ITEM)
96+
rumtuple_get_key(btree->rumstate, itup, &category);
97+
if (category != RUM_CAT_NORM_KEY)
9898
{
99+
Assert(IndexTupleHasNulls(itup));
99100
nitup->t_info |= INDEX_NULL_MASK;
100101
RumSetNullCategory(nitup, category);
101102
}
@@ -487,7 +488,7 @@ entrySplitPage(RumBtree btree, Buffer lbuf, Buffer rbuf,
487488
ptr += MAXALIGN(IndexTupleSize(itup));
488489
}
489490

490-
btree->entry = RumFormInteriorTuple(leftrightmost, newlPage,
491+
btree->entry = RumFormInteriorTuple(btree, leftrightmost, newlPage,
491492
BufferGetBlockNumber(lbuf));
492493

493494
btree->rightblkno = BufferGetBlockNumber(rbuf);
@@ -499,13 +500,13 @@ entrySplitPage(RumBtree btree, Buffer lbuf, Buffer rbuf,
499500
* return newly allocated rightmost tuple
500501
*/
501502
IndexTuple
502-
rumPageGetLinkItup(Buffer buf, Page page)
503+
rumPageGetLinkItup(RumBtree btree, Buffer buf, Page page)
503504
{
504505
IndexTuple itup,
505506
nitup;
506507

507508
itup = getRightMostTuple(page);
508-
nitup = RumFormInteriorTuple(itup, page, BufferGetBlockNumber(buf));
509+
nitup = RumFormInteriorTuple(btree, itup, page, BufferGetBlockNumber(buf));
509510

510511
return nitup;
511512
}
@@ -520,12 +521,12 @@ rumEntryFillRoot(RumBtree btree, Buffer root, Buffer lbuf, Buffer rbuf,
520521
{
521522
IndexTuple itup;
522523

523-
itup = rumPageGetLinkItup(lbuf, lpage);
524+
itup = rumPageGetLinkItup(btree, lbuf, lpage);
524525
if (PageAddItem(page, (Item) itup, IndexTupleSize(itup), InvalidOffsetNumber, false, false) == InvalidOffsetNumber)
525526
elog(ERROR, "failed to add item to index root page");
526527
pfree(itup);
527528

528-
itup = rumPageGetLinkItup(rbuf, rpage);
529+
itup = rumPageGetLinkItup(btree, rbuf, rpage);
529530
if (PageAddItem(page, (Item) itup, IndexTupleSize(itup), InvalidOffsetNumber, false, false) == InvalidOffsetNumber)
530531
elog(ERROR, "failed to add item to index root page");
531532
pfree(itup);

src/backend/access/transam/slru.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ SimpleLruInit(SlruCtl ctl, const char *name, int nslots, int nlsns,
202202
shared->page_dirty = (bool *) (ptr + offset);
203203
offset += MAXALIGN(nslots * sizeof(bool));
204204
shared->page_number = (int64 *) (ptr + offset);
205-
offset += MAXALIGN(nslots * sizeof(int));
205+
offset += MAXALIGN(nslots * sizeof(int64));
206206
shared->page_lru_count = (int *) (ptr + offset);
207207
offset += MAXALIGN(nslots * sizeof(int));
208208

src/bin/pg_dump/pg_backup_db.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1387,7 +1387,11 @@ transferCheckControlData(Archive *fout, const char *transfer_dir, bool isRestore
13871387
}
13881388
else
13891389
{
1390+
#ifdef __GNUC__
13901391
char dumpedInfo[strlen(serverInfo)];
1392+
#else
1393+
char dumpedInfo[1024];
1394+
#endif
13911395
/*
13921396
* In restore mode read info from pg_control in transfer_dir
13931397
* and compare it with the result of select. In case of any

src/include/pgtime.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ extern size_t pg_strftime(char *s, size_t max, const char *format,
7070

7171
/* these functions and variables are in pgtz.c */
7272

73-
extern pg_tz *session_timezone;
73+
extern PGDLLIMPORT pg_tz *session_timezone;
7474
extern pg_tz *log_timezone;
7575

7676
extern void pg_timezone_initialize(void);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy