summaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/common')
-rw-r--r--src/common/socket.c2
-rw-r--r--src/common/socket.h2
-rw-r--r--src/common/strlib.c2
-rw-r--r--src/common/strlib.h2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/common/socket.c b/src/common/socket.c
index 87c98f645..d816767ae 100644
--- a/src/common/socket.c
+++ b/src/common/socket.c
@@ -1101,7 +1101,7 @@ int session_isActive(int fd)
return ( session_isValid(fd) && !session[fd]->eof );
}
-in_addr_t resolve_hostbyname(char* hostname, unsigned char *ip, char *ip_str)
+in_addr_t resolve_hostbyname(const char* hostname, unsigned char* ip, char* ip_str)
{
struct hostent *h = gethostbyname(hostname);
char ip_buf[16];
diff --git a/src/common/socket.h b/src/common/socket.h
index fd8165cba..c56fb8387 100644
--- a/src/common/socket.h
+++ b/src/common/socket.h
@@ -131,7 +131,7 @@ void set_defaultparse(ParseFunc defaultparse);
//hostname is the name to resolve.
//ip is an array of char[4] where the individual parts of the ip are stored (optional)
//ip_str is a char[16] where the whole ip is stored in string notation (optional)
-in_addr_t resolve_hostbyname(char* hostname, unsigned char* ip, char* ip_str);
+in_addr_t resolve_hostbyname(const char* hostname, unsigned char* ip, char* ip_str);
int socket_getips(uint32* ips, int max);
diff --git a/src/common/strlib.c b/src/common/strlib.c
index 440a07742..ee37cb9ae 100644
--- a/src/common/strlib.c
+++ b/src/common/strlib.c
@@ -43,7 +43,7 @@ char* jstrescape (char* pt) {
return &pt[0];
}
-char* jstrescapecpy (char* pt,char* spt) {
+char* jstrescapecpy (char* pt, const char* spt) {
//copy from here
//WARNING: Target string pt should be able to hold strlen(spt)*2, as each time
//a escape character is found, the target's final length increases! [Skotlex]
diff --git a/src/common/strlib.h b/src/common/strlib.h
index 8303c182f..f9a6e41a3 100644
--- a/src/common/strlib.h
+++ b/src/common/strlib.h
@@ -9,7 +9,7 @@
// code by Jioh L. Jung (ziozzang@4wish.net)
// This code is under license "BSD"
char* jstrescape (char* pt);
-char* jstrescapecpy (char* pt,char* spt);
+char* jstrescapecpy (char* pt, const char* spt);
int jmemescapecpy (char* pt,char* spt, int size);
#ifdef __WIN32