summaryrefslogtreecommitdiff
path: root/src/sbuf.h
diff options
context:
space:
mode:
authorrcyeske <rcyeske>2001-02-11 22:18:12 +0000
committerrcyeske <rcyeske>2001-02-11 22:18:12 +0000
commit07f73cc79eec1338f5644baa74647e812340c044 (patch)
treeeecdddaf48774ea9ed10a3ceb73b885de2746d48 /src/sbuf.h
parentbbdeab659ca00996e624c7e9fbce692f4aa66503 (diff)
downloadratpoison-07f73cc79eec1338f5644baa74647e812340c044.zip
*** empty log message ***
Diffstat (limited to 'src/sbuf.h')
-rw-r--r--src/sbuf.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/sbuf.h b/src/sbuf.h
new file mode 100644
index 0000000..a6ff01c
--- /dev/null
+++ b/src/sbuf.h
@@ -0,0 +1,21 @@
+#ifndef _SBUF_H
+#define _SBUF_H
+
+#include <stdlib.h>
+
+struct
+sbuf
+{
+ char *data;
+ size_t len;
+ size_t maxsz;
+};
+
+struct sbuf *sbuf_new (size_t initsz);
+void sbuf_free (struct sbuf *b);
+char *sbuf_concat (struct sbuf *b, const char *str);
+char *sbuf_copy (struct sbuf *b, const char *str);
+char *sbuf_clear (struct sbuf *b);
+char *sbuf_get (struct sbuf *b);
+
+#endif /* _SBUF_H */