diff options
| author | Lorenz Kästle <12514511+RincewindsHat@users.noreply.github.com> | 2026-01-02 13:52:21 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-01-02 13:52:21 +0100 |
| commit | 1e108210b67b4e1a3bfef60d0a7718b8d0080c1a (patch) | |
| tree | 3669cfa7ceb8813f82199f6b9b66ad7f7c5d7b65 /gl/stat.c | |
| parent | e2694816e78986f7a97691dc5b013cbeb7eede4f (diff) | |
| parent | bfc6492562f6cef4badda192142a0d10a3ed870b (diff) | |
| download | monitoring-plugins-1e108210b67b4e1a3bfef60d0a7718b8d0080c1a.tar.gz | |
Merge branch 'master' into netsnmp595-fix
Diffstat (limited to 'gl/stat.c')
| -rw-r--r-- | gl/stat.c | 6 |
1 files changed, 5 insertions, 1 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* Work around platform bugs in stat. | 1 | /* Work around platform bugs in stat. |
| 2 | Copyright (C) 2009-2024 Free Software Foundation, Inc. | 2 | Copyright (C) 2009-2025 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | This file is free software: you can redistribute it and/or modify | 4 | This file is free software: you can redistribute it and/or modify |
| 5 | it under the terms of the GNU Lesser General Public License as | 5 | it under the terms of the GNU Lesser General Public License as |
| @@ -118,6 +118,10 @@ rpl_stat (char const *name, struct stat *buf) | |||
| 118 | around length limitations | 118 | around length limitations |
| 119 | <https://docs.microsoft.com/en-us/windows/desktop/FileIO/naming-a-file> ? */ | 119 | <https://docs.microsoft.com/en-us/windows/desktop/FileIO/naming-a-file> ? */ |
| 120 | 120 | ||
| 121 | /* To ease portability. Like in open.c. */ | ||
| 122 | if (strcmp (name, "/dev/null") == 0) | ||
| 123 | name = "NUL"; | ||
| 124 | |||
| 121 | /* POSIX <https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap04.html#tag_04_13> | 125 | /* POSIX <https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap04.html#tag_04_13> |
| 122 | specifies: "More than two leading <slash> characters shall be treated as | 126 | specifies: "More than two leading <slash> characters shall be treated as |
| 123 | a single <slash> character." */ | 127 | a single <slash> character." */ |
