Skip to content

Commit 13a77d5

Browse files
author
Maxim Orlov
committed
Add support for PostgreSQL 13.
1 parent 7c5081e commit 13a77d5

File tree

2 files changed

+17
-3
lines changed

2 files changed

+17
-3
lines changed

pg_variables.c

+5-2
Original file line numberDiff line numberDiff line change
@@ -2106,8 +2106,11 @@ static void
21062106
compatibility_check(void)
21072107
{
21082108
#ifdef PGPRO_EE
2109-
if (getNestLevelATX() != 0)
2110-
elog(ERROR, "pg_variable extension is not compatible with autonomous transactions and connection pooling");
2109+
# if (PG_VERSION_NUM < 130000) || \
2110+
((PG_VERSION_NUM >= 130000) && (defined PGPRO_FEATURE_ATX))
2111+
if (getNestLevelATX() != 0)
2112+
elog(ERROR, "pg_variable extension is not compatible with autonomous transactions and connection pooling");
2113+
# endif
21112114
#endif
21122115
}
21132116

pg_variables_record.c

+12-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,18 @@
1111
#include "funcapi.h"
1212

1313
#include "access/htup_details.h"
14-
#include "access/tuptoaster.h"
14+
/*
15+
* See https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=8b94dab06617ef80a0901ab103ebd8754427ef
16+
*
17+
* Split tuptoaster.c into three separate files.
18+
*/
19+
#if PG_VERSION_NUM >= 130000
20+
# include "access/detoast.h"
21+
# include "access/heaptoast.h"
22+
#else
23+
# include "access/tuptoaster.h"
24+
#endif
25+
1526
#include "catalog/pg_collation.h"
1627
#include "catalog/pg_type.h"
1728
#include "utils/builtins.h"

0 commit comments

Comments
 (0)