about summary refs log tree commit diff
path: root/redo.c
diff options
context:
space:
mode:
Diffstat (limited to 'redo.c')
-rw-r--r--redo.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/redo.c b/redo.c
index 8398962..3ef8723 100644
--- a/redo.c
+++ b/redo.c
@@ -842,6 +842,8 @@ record_deps(int targetc, char *targetv[])
 	if (dep_fd < 0)
 		return;
 
+	fchdir(dir_fd);
+
 	for (targeti = 0; targeti < targetc; targeti++) {
 		fd = open(targetv[targeti], O_RDONLY);
 		if (fd < 0)