about summary refs log tree commit diff
path: root/src/libstore/references.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstore/references.cc')
-rw-r--r--src/libstore/references.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libstore/references.cc b/src/libstore/references.cc
index 2daf4d4f4d0a..9b20b980a1b2 100644
--- a/src/libstore/references.cc
+++ b/src/libstore/references.cc
@@ -17,6 +17,7 @@ static void search(const string & s,
     for (Strings::iterator i = ids.begin();
          i != ids.end(); )
     {
+        checkInterrupt();
         if (s.find(*i) == string::npos)
             i++;
         else {
@@ -31,6 +32,8 @@ static void search(const string & s,
 void checkPath(const string & path,
     Strings & ids, Strings & seen)
 {
+    checkInterrupt();
+    
     struct stat st;
     if (lstat(path.c_str(), &st))
         throw SysError(format("getting attributes of path `%1%'") % path);