postgres.git / summary / log / commit / refs
commit 9f1ba06c26abbe8ea2fcd229cef742cc068433c6
Author: Robert Haas <rhaas@postgresql.org>
Date: Thu Jul 01 14:11:42 2010 +0000
First released in: 9.0.0, 8.0.26, 8.1.22, 8.2.18, 8.3.12, 8.4.5
Allow ALTER TABLE .. SET TABLESPACE to be interrupted.
Backpatch to 8.0, where tablespaces were introduced.
Guillaume Lelarge
src/backend/commands/tablecmds.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/backend/commands/tablecmds.c b/src/backend/commands/tablecmds.c
index 5897619f777..4181c1a1873 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.242.2.5 2009/12/09 21:58:16 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/tablecmds.c,v 1.242.2.6 2010/07/01 14:11:42 rhaas Exp $
*
*-------------------------------------------------------------------------
*/
@@ -5986,6 +5986,9 @@ copy_relation_data(Relation rel, 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, blkno, buf);
/* XLOG stuff */
[parent: fc1adce4aa00]