summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'util.c')
-rw-r--r--util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/util.c b/util.c
index 9d9c5d3..5116347 100644
--- a/util.c
+++ b/util.c
@@ -10,14 +10,14 @@
#include "util.h"
-char* copy_buf(char *buf,int len){
+char* copy_buf(const char *buf,int len){
char *dst=malloc(len+1,char);
memcpy(dst,buf,len);
dst[len]='\0';
return dst;
}
-char* copy_str(char *str){
+char* copy_str(const char *str){
return copy_buf(str,strlen(str));
}