summaryrefslogtreecommitdiff
path: root/src/backend/commands
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/commands')
-rw-r--r--src/backend/commands/portalcmds.c4
-rw-r--r--src/backend/commands/trigger.c9
-rw-r--r--src/backend/commands/vacuum.c9
3 files changed, 11 insertions, 11 deletions
diff --git a/src/backend/commands/portalcmds.c b/src/backend/commands/portalcmds.c
index b3170499adc..affbe2b3e49 100644
--- a/src/backend/commands/portalcmds.c
+++ b/src/backend/commands/portalcmds.c
@@ -14,7 +14,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/commands/portalcmds.c,v 1.40 2005/04/11 15:59:34 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/portalcmds.c,v 1.41 2005/04/28 21:47:11 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -90,7 +90,7 @@ PerformCursorOpen(DeclareCursorStmt *stmt, ParamListInfo params)
if (query->rowMarks != NIL)
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
- errmsg("DECLARE CURSOR ... FOR UPDATE is not supported"),
+ errmsg("DECLARE CURSOR ... FOR UPDATE/SHARE is not supported"),
errdetail("Cursors must be READ ONLY.")));
plan = planner(query, true, stmt->options, NULL);
diff --git a/src/backend/commands/trigger.c b/src/backend/commands/trigger.c
index c298cba3047..70759b9d76a 100644
--- a/src/backend/commands/trigger.c
+++ b/src/backend/commands/trigger.c
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/commands/trigger.c,v 1.186 2005/04/14 20:03:24 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/trigger.c,v 1.187 2005/04/28 21:47:11 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1592,12 +1592,12 @@ GetTupleForTrigger(EState *estate, ResultRelInfo *relinfo,
HTSU_Result test;
/*
- * mark tuple for update
+ * lock tuple for update
*/
*newSlot = NULL;
tuple.t_self = *tid;
ltrmark:;
- test = heap_mark4update(relation, &tuple, &buffer, cid);
+ test = heap_lock_tuple(relation, &tuple, &buffer, cid, LockTupleExclusive);
switch (test)
{
case HeapTupleSelfUpdated:
@@ -1636,8 +1636,7 @@ ltrmark:;
default:
ReleaseBuffer(buffer);
- elog(ERROR, "unrecognized heap_mark4update status: %u",
- test);
+ elog(ERROR, "invalid heap_lock_tuple status: %d", test);
return NULL; /* keep compiler quiet */
}
}
diff --git a/src/backend/commands/vacuum.c b/src/backend/commands/vacuum.c
index f52e9ecb3c2..ba432887571 100644
--- a/src/backend/commands/vacuum.c
+++ b/src/backend/commands/vacuum.c
@@ -13,7 +13,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/commands/vacuum.c,v 1.306 2005/04/14 20:03:24 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/vacuum.c,v 1.307 2005/04/28 21:47:12 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1800,7 +1800,7 @@ repair_frag(VRelStats *vacrelstats, Relation onerel,
!TransactionIdPrecedes(HeapTupleHeaderGetXmin(tuple.t_data),
OldestXmin)) ||
(!(tuple.t_data->t_infomask & (HEAP_XMAX_INVALID |
- HEAP_MARKED_FOR_UPDATE)) &&
+ HEAP_IS_LOCKED)) &&
!(ItemPointerEquals(&(tuple.t_self),
&(tuple.t_data->t_ctid)))))
{
@@ -1839,7 +1839,7 @@ repair_frag(VRelStats *vacrelstats, Relation onerel,
* we have to move to the end of chain.
*/
while (!(tp.t_data->t_infomask & (HEAP_XMAX_INVALID |
- HEAP_MARKED_FOR_UPDATE)) &&
+ HEAP_IS_LOCKED)) &&
!(ItemPointerEquals(&(tp.t_self),
&(tp.t_data->t_ctid))))
{
@@ -1984,7 +1984,8 @@ repair_frag(VRelStats *vacrelstats, Relation onerel,
* and we are too close to 6.5 release. - vadim
* 06/11/99
*/
- if (!(TransactionIdEquals(HeapTupleHeaderGetXmax(Ptp.t_data),
+ if (Ptp.t_data->t_infomask & HEAP_XMAX_IS_MULTI ||
+ !(TransactionIdEquals(HeapTupleHeaderGetXmax(Ptp.t_data),
HeapTupleHeaderGetXmin(tp.t_data))))
{
ReleaseBuffer(Pbuf);