aboutsummaryrefslogtreecommitdiffstats
path: root/src/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/util.c b/src/util.c
index 64b5bd0..4dc6e9c 100644
--- a/src/util.c
+++ b/src/util.c
@@ -1,4 +1,5 @@
#include <stdio.h>
+#include <string.h>
/* This function fucking sucks and should use something else. I'll
* have to rewrite this shit function some day. But for now, it will
@@ -23,3 +24,11 @@ get_tokens_from_file(char *filename, char *instance, char *client_id,
return 0;
}
+
+size_t
+write_data(void *buffer, size_t size, size_t nmemb, void *userp)
+{
+
+ memcpy(userp,buffer,nmemb*size);
+ return 0;
+}