errmsg("argument must be empty or one-dimensional array")));
}
+static void
+check_tidstore_available(void)
+{
+ if (tidstore == NULL)
+ elog(ERROR, "tidstore is not created");
+}
+
static void
purge_from_verification_array(BlockNumber blkno)
{
OffsetNumber *offs;
int noffs;
+ check_tidstore_available();
sanity_check_array(ta);
noffs = ArrayGetNItems(ARR_NDIM(ta), ARR_DIMS(ta));
int num_lookup_tids = 0;
BlockNumber prevblkno = 0;
+ check_tidstore_available();
+
/* lookup each member in the verification array */
for (int i = 0; i < items.num_tids; i++)
if (!TidStoreIsMember(tidstore, &items.insert_tids[i]))
{
bool is_full;
+ check_tidstore_available();
+
is_full = (TidStoreMemoryUsage(tidstore) > tidstore_empty_size);
PG_RETURN_BOOL(is_full);
Datum
test_destroy(PG_FUNCTION_ARGS)
{
+ check_tidstore_available();
+
TidStoreDestroy(tidstore);
tidstore = NULL;
items.num_tids = 0;