aboutsummaryrefslogtreecommitdiffstats
path: root/src/misc.h
diff options
context:
space:
mode:
authorMartin Pärtel <martin.partel@gmail.com>2015-11-17 10:34:53 +0000
committerMartin Pärtel <martin.partel@gmail.com>2015-11-17 10:34:53 +0000
commit85d6a8c10ec9469c80382fb0b9e9bb0d2ec7c520 (patch)
treee3fc2ef99a0beb79a650ea437bbfa4c30e8bcef5 /src/misc.h
parent6b56b050c0e4240389e52f47502acd43d50874c0 (diff)
downloadbindfs-85d6a8c10ec9469c80382fb0b9e9bb0d2ec7c520.tar.gz
Show the source dir in the first field on /etc/mtab.
Fixes #15. Thanks @tyll!
Diffstat (limited to 'src/misc.h')
-rw-r--r--src/misc.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/misc.h b/src/misc.h
index dc654d6..b059596 100644
--- a/src/misc.h
+++ b/src/misc.h
@@ -31,6 +31,9 @@ int count_substrs(const char *s, const char *sub);
an end character is reached. */
char *strdup_until(const char *s, const char *endchars);
+/* Like sprintf but writes to an automatically malloc'ed buffer. */
+char *sprintf_new(const char *format, ...);
+
/* Returns a pointer to the first character after the
final slash of path, or path itself if it contains no slashes.
If the path ends with a slash, then the result is an empty