summaryrefslogtreecommitdiff
path: root/src/basic/fs-util.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2018-02-10 12:47:12 +0900
committerGitHub <noreply@github.com>2018-02-10 12:47:12 +0900
commitb8e2400586452499131ff5ab1edb60c1dfbcf92b (patch)
treedf4f30f4a403391983f9c4005049182338bc12ef /src/basic/fs-util.c
parentaa9122bf3d52fb7e4e7638d1e8e3a3c5cc3c2694 (diff)
parent92db49a0c2ee6fda0eff842c40d7298b938b99ba (diff)
downloadsystemd-b8e2400586452499131ff5ab1edb60c1dfbcf92b.tar.gz
Merge pull request #8143 from yuwata/drop-unused-func
Drop several unused functions
Diffstat (limited to 'src/basic/fs-util.c')
-rw-r--r--src/basic/fs-util.c43
1 files changed, 0 insertions, 43 deletions
diff --git a/src/basic/fs-util.c b/src/basic/fs-util.c
index a8e50d4c78..cf856ae8e2 100644
--- a/src/basic/fs-util.c
+++ b/src/basic/fs-util.c
@@ -225,49 +225,6 @@ int readlink_and_make_absolute(const char *p, char **r) {
return 0;
}
-int readlink_and_canonicalize(const char *p, const char *root, char **ret) {
- char *t, *s;
- int r;
-
- assert(p);
- assert(ret);
-
- r = readlink_and_make_absolute(p, &t);
- if (r < 0)
- return r;
-
- r = chase_symlinks(t, root, 0, &s);
- if (r < 0)
- /* If we can't follow up, then let's return the original string, slightly cleaned up. */
- *ret = path_kill_slashes(t);
- else {
- *ret = s;
- free(t);
- }
-
- return 0;
-}
-
-int readlink_and_make_absolute_root(const char *root, const char *path, char **ret) {
- _cleanup_free_ char *target = NULL, *t = NULL;
- const char *full;
- int r;
-
- full = prefix_roota(root, path);
- r = readlink_malloc(full, &target);
- if (r < 0)
- return r;
-
- t = file_in_same_dir(path, target);
- if (!t)
- return -ENOMEM;
-
- *ret = t;
- t = NULL;
-
- return 0;
-}
-
int chmod_and_chown(const char *path, mode_t mode, uid_t uid, gid_t gid) {
assert(path);