Bug#909789: manpages-dev: stat(2) manpage on ENOENT for dangling symbolic links (broken links)
On Fri, Sep 28, 2018 at 10:14:21PM +0200, Michael Kerrisk (man-opages) wrote: > [...] > It's not merely a question of a broken symlink in the final pathname > component, which lstat() could address. ENOENT can also occur if any > component in the pathname is a dangling symbolic link. So I changed the > ENOENT text to: > >ENOENT A component of pathname does not exist or is a > dangling symbolic link. > >ENOENT pathname is an empty string and AT_EMPTY_PATH was > not specified in flags. Confirmed to be present in man-pages-5.00 (first packaged in Debian in 5.01-1), hence this bug could be closed accordingly. > > Besides, the 1st paragraph in the NOTES section says "AT_NO_AUTOMOUNT fag". > > Please substitute "AT_NO_AUTOMOUNT flag" lest someone smokes their unmounted > > devices... > > :-) > > In fact, that text was fixed about a year ago, so you don't have quite > the most up-to-date pages :-). Also confirmed to be fixed. Cheers, Flo signature.asc Description: PGP signature
Bug#909789: manpages-dev: stat(2) manpage on ENOENT for dangling symbolic links (broken links)
tags 909789 fixed-upstream thanks -- Michael Kerrisk Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/ Linux/UNIX System Programming Training: http://man7.org/training/
Bug#909789: manpages-dev: stat(2) manpage on ENOENT for dangling symbolic links (broken links)
tags fixed-upstream thanks On 09/28/2018 01:38 PM, Alessandro Vesely wrote: Package: manpages-dev Version: 4.10-2 Severity: minor Dear Maintainer, Hello Ale, Upstream maintainer here... it seems to be a gotcha having stat(x, y) unexpectedly return -1 when x is a broken link. The stat(1) command works where stat(2) fails. The obvious solution is to use lstat. It is difficult to fix this without ineffectually lengthening the text. Perhaps, using the concept of unlinked file, which is valid for hard and soft links alike, might help. For example, the man page says: ENOENT A component of pathname does not exist, or pathname is an empty string. Alternatively, it could say: ENOENT A component of pathname is unlinked (does not exist), or pathname is an empty string. Thanks for your report! It's not merely a question of a broken symlink in the final pathname component, which lstat() could address. ENOENT can also occur if any component in the pathname is a dangling symbolic link. So I changed the ENOENT text to: ENOENT A component of pathname does not exist or is a dangling symbolic link. ENOENT pathname is an empty string and AT_EMPTY_PATH was not specified in flags. Besides, the 1st paragraph in the NOTES section says "AT_NO_AUTOMOUNT fag". Please substitute "AT_NO_AUTOMOUNT flag" lest someone smokes their unmounted devices... :-) In fact, that text was fixed about a year ago, so you don't have quite the most up-to-date pages :-). Thanks for maintaining man pages You are welcome! Cheers, Michael -- System Information: Debian Release: 9.5 APT prefers stable APT policy: (500, 'stable') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 4.9.0-8-amd64 (SMP w/4 CPU cores) Locale: LANG=en_IE.UTF-8, LC_CTYPE=en_IE.UTF-8 (charmap=UTF-8), LANGUAGE=en_IE.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Init: sysvinit (via /sbin/init) Versions of packages manpages-dev depends on: ii manpages 4.10-2 manpages-dev recommends no packages. Versions of packages manpages-dev suggests: ii jed-extra [man-browser] 2.5.7-2 ii man-db [man-browser] 2.7.6.1-2
Bug#909789: manpages-dev: stat(2) manpage on ENOENT for dangling symbolic links (broken links)
Package: manpages-dev Version: 4.10-2 Severity: minor Dear Maintainer, it seems to be a gotcha having stat(x, y) unexpectedly return -1 when x is a broken link. The stat(1) command works where stat(2) fails. The obvious solution is to use lstat. It is difficult to fix this without ineffectually lengthening the text. Perhaps, using the concept of unlinked file, which is valid for hard and soft links alike, might help. For example, the man page says: ENOENT A component of pathname does not exist, or pathname is an empty string. Alternatively, it could say: ENOENT A component of pathname is unlinked (does not exist), or pathname is an empty string. Besides, the 1st paragraph in the NOTES section says "AT_NO_AUTOMOUNT fag". Please substitute "AT_NO_AUTOMOUNT flag" lest someone smokes their unmounted devices... Thanks for maintaining man pages Ale -- System Information: Debian Release: 9.5 APT prefers stable APT policy: (500, 'stable') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 4.9.0-8-amd64 (SMP w/4 CPU cores) Locale: LANG=en_IE.UTF-8, LC_CTYPE=en_IE.UTF-8 (charmap=UTF-8), LANGUAGE=en_IE.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Init: sysvinit (via /sbin/init) Versions of packages manpages-dev depends on: ii manpages 4.10-2 manpages-dev recommends no packages. Versions of packages manpages-dev suggests: ii jed-extra [man-browser] 2.5.7-2 ii man-db [man-browser] 2.7.6.1-2