network: let get_ip_string() return const char * instead of const char

Signed-off-by: Michael Adam <obnox@samba.org>
This commit is contained in:
Michael Adam 2017-03-29 23:56:48 +02:00
parent f149b62475
commit a71cebb094
2 changed files with 2 additions and 2 deletions

View File

@ -249,7 +249,7 @@ CLEANUP:
* Convert the network address into either a dotted-decimal or an IPv6 * Convert the network address into either a dotted-decimal or an IPv6
* hex string. * hex string.
*/ */
char *get_ip_string (struct sockaddr *sa, char *buf, size_t buflen) const char *get_ip_string (struct sockaddr *sa, char *buf, size_t buflen)
{ {
assert (sa != NULL); assert (sa != NULL);
assert (buf != NULL); assert (buf != NULL);

View File

@ -27,7 +27,7 @@ extern ssize_t safe_read (int fd, char *buffer, size_t count);
extern int write_message (int fd, const char *fmt, ...); extern int write_message (int fd, const char *fmt, ...);
extern ssize_t readline (int fd, char **whole_buffer); extern ssize_t readline (int fd, char **whole_buffer);
extern char *get_ip_string (struct sockaddr *sa, char *buf, size_t len); extern const char *get_ip_string (struct sockaddr *sa, char *buf, size_t len);
extern int full_inet_pton (const char *ip, void *dst); extern int full_inet_pton (const char *ip, void *dst);
#endif #endif