aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRobert Haas <rhaas@postgresql.org>2010-07-01 14:12:04 +0000
committerRobert Haas <rhaas@postgresql.org>2010-07-01 14:12:04 +0000
commite61665f118a67325f32c769f7ea99764d1d6439f (patch)
treee435280c8c0f6a8402c638b8fcf06e241843d8b8 /src
parentff06716e3dafc73820ed38f6eea2c6d6dcae7fd9 (diff)
downloadpostgresql-e61665f118a67325f32c769f7ea99764d1d6439f.tar.gz
postgresql-e61665f118a67325f32c769f7ea99764d1d6439f.zip
Allow ALTER TABLE .. SET TABLESPACE to be interrupted.
Backpatch to 8.0, where tablespaces were introduced. Guillaume Lelarge
Diffstat (limited to 'src')
-rw-r--r--src/backend/commands/tablecmds.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/backend/commands/tablecmds.c b/src/backend/commands/tablecmds.c
index 632c9d8d388..3a899125a62 100644
--- a/src/backend/commands/tablecmds.c
+++ b/src/backend/commands/tablecmds.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/commands/tablecmds.c,v 1.288.2.3 2009/12/09 21:58:04 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/tablecmds.c,v 1.288.2.4 2010/07/01 14:12:04 rhaas Exp $
*
*-------------------------------------------------------------------------
*/
@@ -6838,6 +6838,9 @@ copy_relation_data(SMgrRelation src, SMgrRelation dst,
for (blkno = 0; blkno < nblocks; blkno++)
{
+ /* If we got a cancel signal during the copy of the data, quit */
+ CHECK_FOR_INTERRUPTS();
+
smgrread(src, forkNum, blkno, buf);
/* XLOG stuff */