summaryrefslogtreecommitdiff
path: root/module
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2011-12-19 22:25:30 +0100
committerLudovic Courtès <ludo@gnu.org>2011-12-19 22:25:30 +0100
commita2c66014cf4b8799812e45eedbb9b1a2c61236b0 (patch)
tree585440078e0d4220e929ed0034f6f4b7744949af /module
parent52b680f85e84689778f10ed8f9e72adf8316fbe7 (diff)
ftw: Include sub-directories in the result of `scandir'.
* module/ice-9/ftw.scm (scandir)[skip]: Keep NAME in the resulting list. * test-suite/tests/ftw.test ("scandir")["top-srcdir"]: New test.
Diffstat (limited to 'module')
-rw-r--r--module/ice-9/ftw.scm2
1 files changed, 1 insertions, 1 deletions
diff --git a/module/ice-9/ftw.scm b/module/ice-9/ftw.scm
index eed3eeb19..5f6115427 100644
--- a/module/ice-9/ftw.scm
+++ b/module/ice-9/ftw.scm
@@ -530,7 +530,7 @@ of file names is sorted according to ENTRY<?, which defaults to
(define (skip name stat result)
;; All the sub-directories are skipped.
- result)
+ (cons (basename name) result))
(and=> (file-system-fold enter? leaf down up skip #f name stat)
(lambda (files)