@@ -674,7 +674,11 @@ plugin_change(LogicalDecodingContext *ctx, ReorderBufferTXN *txn,
674674 HeapTuple newtuple ;
675675
676676 newtuple = change -> data .tp .newtuple != NULL ?
677+ #if PG_VERSION_NUM >= 170000
678+ change -> data .tp .newtuple : NULL ;
679+ #else
677680 & change -> data .tp .newtuple -> tuple : NULL;
681+ #endif
678682
679683 /*
680684 * Identity checks in the main function should have made this
@@ -692,9 +696,17 @@ plugin_change(LogicalDecodingContext *ctx, ReorderBufferTXN *txn,
692696 newtuple ;
693697
694698 oldtuple = change -> data .tp .oldtuple != NULL ?
699+ #if PG_VERSION_NUM >= 170000
700+ change -> data .tp .oldtuple : NULL ;
701+ #else
695702 & change -> data .tp .oldtuple -> tuple : NULL;
703+ #endif
696704 newtuple = change -> data .tp .newtuple != NULL ?
705+ #if PG_VERSION_NUM >= 170000
706+ change -> data .tp .newtuple : NULL ;
707+ #else
697708 & change -> data .tp .newtuple -> tuple : NULL;
709+ #endif
698710
699711 if (newtuple == NULL )
700712 elog (ERROR , "Incomplete update info." );
@@ -710,7 +722,11 @@ plugin_change(LogicalDecodingContext *ctx, ReorderBufferTXN *txn,
710722 HeapTuple oldtuple ;
711723
712724 oldtuple = change -> data .tp .oldtuple ?
725+ #if PG_VERSION_NUM >= 170000
726+ change -> data .tp .oldtuple : NULL ;
727+ #else
713728 & change -> data .tp .oldtuple -> tuple : NULL;
729+ #endif
714730
715731 if (oldtuple == NULL )
716732 elog (ERROR , "Incomplete delete info." );
0 commit comments