aboutsummaryrefslogtreecommitdiff
path: root/src/utils.h
diff options
context:
space:
mode:
authorAleksey Veresov <aleksey@veresov.pro>2019-11-29 18:50:04 +0300
committerAleksey Veresov <aleksey@veresov.pro>2019-11-29 18:50:04 +0300
commitb08db17162fddda97e6ee1ac625eae1430d22b64 (patch)
tree2c332f2db57a15c72f58704b9175cfece0ae9698 /src/utils.h
parentea25abb295d9b4fbaf0ac23af8ffe71247970f1b (diff)
downloadmagi-b08db17162fddda97e6ee1ac625eae1430d22b64.tar
magi-b08db17162fddda97e6ee1ac625eae1430d22b64.tar.xz
magi-b08db17162fddda97e6ee1ac625eae1430d22b64.zip
[magi] Almost done!
Diffstat (limited to 'src/utils.h')
-rw-r--r--src/utils.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/utils.h b/src/utils.h
index 15904d0..f67c66c 100644
--- a/src/utils.h
+++ b/src/utils.h
@@ -2,10 +2,14 @@
#define MAGI_INCLUDED_UTILS
-void magi_str_lowercase(char * str);
+void magi_str_lowercase(char * str);
+
+/* Results of both create functions are malloced, so need to be freed. */
char * magi_str_create_copy(const char * begin, const char * end);
char * magi_str_create(int len);
-char * magi_str_add(char * dest, int * len, int * size, char c);
+
+/* Null only in case of error. */
+int magi_str_add(char ** dest, int * len, int * size, char c);
#endif