[PATCH 1/5] libquota: remove get_qf_path()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This function isn't used anywhere, so remove it.  It also uses
PATH_MAX which is not portable.

Cc: Aditya Kali <adityakali@xxxxxxxxxx>
Signed-off-by: "Theodore Ts'o" <tytso@xxxxxxx>
---
 lib/quota/mkquota.h |    2 --
 lib/quota/quotaio.c |   18 ------------------
 2 files changed, 0 insertions(+), 20 deletions(-)

diff --git a/lib/quota/mkquota.h b/lib/quota/mkquota.h
index b4eba14..00d3c2f 100644
--- a/lib/quota/mkquota.h
+++ b/lib/quota/mkquota.h
@@ -60,7 +60,5 @@ void set_sb_quota_inum(ext2_filsys fs, ext2_ino_t ino, int qtype);
 
 /* in quotaio.c */
 const char *get_qf_name(int type, int fmt, char *buf);
-const char *get_qf_path(const char *mntpt, int qtype, int fmt,
-			char *path_buf, size_t path_buf_size);
 
 #endif  /* __QUOTA_QUOTAIO_H__ */
diff --git a/lib/quota/quotaio.c b/lib/quota/quotaio.c
index 7e080c8..cf13e35 100644
--- a/lib/quota/quotaio.c
+++ b/lib/quota/quotaio.c
@@ -61,24 +61,6 @@ const char *get_qf_name(int type, int fmt, char *buf)
 	return buf;
 }
 
-const char *get_qf_path(const char *mntpt, int qtype, int fmt,
-			char *path_buf, size_t path_buf_size)
-{
-	struct stat	qf_stat;
-	char qf_name[PATH_MAX] = {0};
-
-	BUG_ON(!mntpt);
-	BUG_ON(!path_buf);
-	BUG_ON(!path_buf_size);
-
-	strncpy(path_buf, mntpt, path_buf_size);
-	strncat(path_buf, "/", 1);
-	strncat(path_buf, get_qf_name(qtype, fmt, qf_name),
-		path_buf_size - strlen(path_buf));
-
-	return path_buf;
-}
-
 /*
  * Set grace time if needed
  */
-- 
1.7.4.1.22.gec8e1.dirty

--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux