From 907faf600f4d95eaae4b5c2fc0e8bc06c3efe48e Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Sat, 25 Feb 2012 14:27:43 +0000 Subject: Do not recurse through a symlink given as root --- summain | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'summain') diff --git a/summain b/summain index a9e7ead..b82c108 100755 --- a/summain +++ b/summain @@ -122,7 +122,7 @@ class Summain(cliapp.Application): 'choose output format (rfc822, csv, json)') def files(self, root): - if os.path.isdir(root): + if os.path.isdir(root) and not os.path.islink(root): for dirname, dirnames, filenames in os.walk(root): yield dirname dirnames.sort() -- cgit v1.2.1