[systemd-devel] [PATCH] shared: remove unused functions

Ronny Chevalier chevalier.ronny at gmail.com
Sat Oct 11 09:43:12 PDT 2014


- mkdir_p_prefix: It has never been used
- mkdir_parents_prefix_label: Unused since 1434ae6fd49f8377b0ddbd4c675736e0d3226ea6
---
 src/shared/mkdir-label.c | 4 ----
 src/shared/mkdir.c       | 4 ----
 src/shared/mkdir.h       | 2 --
 3 files changed, 10 deletions(-)

diff --git a/src/shared/mkdir-label.c b/src/shared/mkdir-label.c
index 4ee6251..43ea2c2 100644
--- a/src/shared/mkdir-label.c
+++ b/src/shared/mkdir-label.c
@@ -44,10 +44,6 @@ int mkdir_parents_label(const char *path, mode_t mode) {
         return mkdir_parents_internal(NULL, path, mode, label_mkdir);
 }
 
-int mkdir_parents_prefix_label(const char *prefix, const char *path, mode_t mode) {
-        return mkdir_parents_internal(prefix, path, mode, label_mkdir);
-}
-
 int mkdir_p_label(const char *path, mode_t mode) {
         return mkdir_p_internal(NULL, path, mode, label_mkdir);
 }
diff --git a/src/shared/mkdir.c b/src/shared/mkdir.c
index f941efb..fabd9e2 100644
--- a/src/shared/mkdir.c
+++ b/src/shared/mkdir.c
@@ -144,7 +144,3 @@ int mkdir_p_internal(const char *prefix, const char *path, mode_t mode, mkdir_fu
 int mkdir_p(const char *path, mode_t mode) {
         return mkdir_p_internal(NULL, path, mode, mkdir);
 }
-
-int mkdir_p_prefix(const char *prefix, const char *path, mode_t mode) {
-        return mkdir_p_internal(prefix, path, mode, mkdir);
-}
diff --git a/src/shared/mkdir.h b/src/shared/mkdir.h
index dd5b41e..ca38d21 100644
--- a/src/shared/mkdir.h
+++ b/src/shared/mkdir.h
@@ -28,14 +28,12 @@
 int mkdir_safe(const char *path, mode_t mode, uid_t uid, gid_t gid);
 int mkdir_parents(const char *path, mode_t mode);
 int mkdir_p(const char *path, mode_t mode);
-int mkdir_p_prefix(const char *prefix, const char *path, mode_t mode);
 
 /* selinux versions */
 int mkdir_label(const char *path, mode_t mode);
 int mkdir_safe_label(const char *path, mode_t mode, uid_t uid, gid_t gid);
 int mkdir_parents_label(const char *path, mode_t mode);
 int mkdir_p_label(const char *path, mode_t mode);
-int mkdir_parents_prefix_label(const char *prefix, const char *path, mode_t mode);
 
 /* internally used */
 typedef int (*mkdir_func_t)(const char *pathname, mode_t mode);
-- 
2.1.2



More information about the systemd-devel mailing list