From: Steve Holden Date: Tue, 6 Aug 2002 16:07:07 +0000 (+0000) Subject: Add comment about os.path.walk()'s behavior with symbolic links. X-Git-Tag: v2.3c1~4674 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=545092b063e235bb81706a296ed18618d4293b87;p=thirdparty%2FPython%2Fcpython.git Add comment about os.path.walk()'s behavior with symbolic links. --- diff --git a/Doc/lib/libposixpath.tex b/Doc/lib/libposixpath.tex index 4bbb5b6e5690..d19544732b0d 100644 --- a/Doc/lib/libposixpath.tex +++ b/Doc/lib/libposixpath.tex @@ -214,4 +214,9 @@ influence the set of directories visited below \var{dirname}, e.g., to avoid visiting certain parts of the tree. (The object referred to by \var{names} must be modified in place, using \keyword{del} or slice assignment.) + +Note that symbolic links to directories are not treated as subdirectories, +and that \var{walk} therefore will not visit them. To visit linked +directories you must identify them with \var{os.path.islink(file)} and +\var{os.path.isdir(file)}, and invoke \function{walk()} as necessary. \end{funcdesc}