From 6533f6632e2898b8bdf3012b51b924e676b4b5dd Mon Sep 17 00:00:00 2001 From: Yugo Nagata Date: Mon, 26 May 2025 11:43:09 +0900 Subject: [PATCH] Fix potential segmentation fault in create_immv Ensure that newly added column information is passed to heap_form_tuple(). Previously, omission of this data led to a segmentation fault when building with MSVC, though the issue has not not observed on Linux. --- createas.c | 1 + 1 file changed, 1 insertion(+) diff --git a/createas.c b/createas.c index b41fd1d..1691074 100644 --- a/createas.c +++ b/createas.c @@ -1723,6 +1723,7 @@ StoreImmvQuery(Oid viewOid, Query *viewQuery) values[Anum_pg_ivm_immv_immvrelid -1 ] = ObjectIdGetDatum(viewOid); values[Anum_pg_ivm_immv_ispopulated -1 ] = BoolGetDatum(false); values[Anum_pg_ivm_immv_viewdef -1 ] = CStringGetTextDatum(querytree); + isNulls[Anum_pg_ivm_immv_lastivmupdate -1 ] = true; pgIvmImmv = table_open(PgIvmImmvRelationId(), RowExclusiveLock);