From 0bea7672957f142d8af58d04ade70b91e7ffb727 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Sat, 14 Nov 2015 05:21:46 +0100 Subject: doc: cleanname is not symlink-safe either MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- include/libgen.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include') diff --git a/include/libgen.h b/include/libgen.h index d417739..182f192 100644 --- a/include/libgen.h +++ b/include/libgen.h @@ -64,6 +64,10 @@ char* dirname(char*) * '..' directory components that should resolve up beyond '/', * are removed. Note that this can in fact mean that the resulting * path is not the same file if the processes is `chroot`:ed. + * Additionally, and more important, there is no consideration for + * symbolic links. For example, '/a/b/c/..' resolves to '/a/b', + * but if any of the directors are symbolic links, the real path + * is not necessarily '/a/b'. * * This is a slibc extension. * -- cgit v1.2.3-70-g09d2