Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit efe3e12

Browse files
committed
Correctly drop not comletely constucted index
1 parent ea35e34 commit efe3e12

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

lsm3.c

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -971,11 +971,14 @@ lsm3_process_utility(PlannedStmt *plannedStmt,
971971
}
972972
for (int i = 0; i < 2; i++)
973973
{
974-
ObjectAddress obj;
975-
obj.classId = RelationRelationId;
976-
obj.objectId = entry->top[i];
977-
obj.objectSubId = 0;
978-
add_exact_object_address(&obj, drop_objects);
974+
if (entry->top[i])
975+
{
976+
ObjectAddress obj;
977+
obj.classId = RelationRelationId;
978+
obj.objectId = entry->top[i];
979+
obj.objectSubId = 0;
980+
add_exact_object_address(&obj, drop_objects);
981+
}
979982
}
980983
drop_oids = lappend_oid(drop_oids, RelationGetRelid(index));
981984
}

0 commit comments

Comments
 (0)