/src/util-linux/include/canonicalize.h
Line | Count | Source (jump to first uncovered line) |
1 | | /* |
2 | | * This program is free software; you can redistribute it and/or modify |
3 | | * it under the terms of the GNU Library Public License as published by |
4 | | * the Free Software Foundation; either version 2, or (at your option) |
5 | | * any later version. |
6 | | * |
7 | | * This program is distributed in the hope that it will be useful, |
8 | | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
9 | | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
10 | | * GNU Library Public License for more details. |
11 | | */ |
12 | | #ifndef CANONICALIZE_H |
13 | | #define CANONICALIZE_H |
14 | | |
15 | | #include "c.h" /* for PATH_MAX */ |
16 | | #include "strutils.h" |
17 | | |
18 | | extern char *canonicalize_path(const char *path); |
19 | | extern char *canonicalize_path_restricted(const char *path); |
20 | | extern char *canonicalize_dm_name(const char *ptname); |
21 | | extern char *__canonicalize_dm_name(const char *prefix, const char *ptname); |
22 | | |
23 | | extern char *absolute_path(const char *path); |
24 | | |
25 | | static inline int is_relative_path(const char *path) |
26 | 0 | { |
27 | 0 | if (!path || *path == '/') |
28 | 0 | return 0; |
29 | 0 | return 1; |
30 | 0 | } Unexecuted instantiation: devname.c:is_relative_path Unexecuted instantiation: canonicalize.c:is_relative_path |
31 | | |
32 | | #endif /* CANONICALIZE_H */ |