PostgreSQL Source Code git master
|
#include "storage/bufpage.h"
#include "storage/lmgr.h"
#include "storage/lockdefs.h"
#include "utils/relcache.h"
#include "miscadmin.h"
Go to the source code of this file.
Typedefs | |
typedef void(* | IndexCheckableCallback) (Relation index) |
typedef void(* | IndexDoCheckCallback) (Relation rel, Relation heaprel, void *state, bool readonly) |
Functions | |
void | amcheck_lock_relation_and_check (Oid indrelid, Oid am_id, IndexDoCheckCallback check, LOCKMODE lockmode, void *state) |
bool | index_checkable (Relation rel, Oid am_id) |
Definition at line 20 of file verify_common.h.
Definition at line 21 of file verify_common.h.
void amcheck_lock_relation_and_check | ( | Oid | indrelid, |
Oid | am_id, | ||
IndexDoCheckCallback | check, | ||
LOCKMODE | lockmode, | ||
void * | state | ||
) |
Definition at line 60 of file verify_common.c.
References AtEOXact_GUC(), ereport, errcode(), ERRCODE_UNDEFINED_TABLE, errmsg(), ERROR, GetUserIdAndSecContext(), index_checkable(), index_close(), index_open(), IndexGetRelation(), InvalidOid, NewGUCNestLevel(), OidIsValid, RelationData::rd_rel, RelationGetRelationName, SECURITY_RESTRICTED_OPERATION, SetUserIdAndSecContext(), ShareLock, table_close(), and table_open().
Referenced by bt_index_check(), bt_index_parent_check(), and gin_index_check().
Definition at line 159 of file verify_common.c.
References amcheck_index_mainfork_expected(), ereport, errcode(), errdetail(), errmsg(), ERROR, GETSTRUCT(), NameStr, ObjectIdGetDatum(), RelationData::rd_index, RelationData::rd_rel, RELATION_IS_OTHER_TEMP, RelationGetRelationName, and SearchSysCache1().
Referenced by amcheck_lock_relation_and_check().