summaryrefslogtreecommitdiff
path: root/source/nsswitch
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2008-04-20 22:13:40 +0200
committerGerald W. Carter <jerry@samba.org>2008-04-23 13:49:50 -0500
commit5f4b77eb63f72a3004c0c7e760e85fa08c339a7d (patch)
tree1d2aff376e4a9afe4cb3f48a63df3b30bcd6f278 /source/nsswitch
parentc174826ee57b1b3b34eec080ca6474c9cc34cfa0 (diff)
downloadsamba-5f4b77eb63f72a3004c0c7e760e85fa08c339a7d.tar.gz
libwbclient: fix wbcResolveWinsByName() to take char * instead of const char **
This fixes a compile warning and seems the correct thing to me as the returned data is talloc_strdup't, so not const anyways. Michael (cherry picked from commit 13cfa7f48a541a934a129fab0544cbf66029c4c7)
Diffstat (limited to 'source/nsswitch')
-rw-r--r--source/nsswitch/libwbclient/wbc_util.c4
-rw-r--r--source/nsswitch/libwbclient/wbclient.h2
-rw-r--r--source/nsswitch/wbinfo.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/source/nsswitch/libwbclient/wbc_util.c b/source/nsswitch/libwbclient/wbc_util.c
index b8394ed6615..09c11521352 100644
--- a/source/nsswitch/libwbclient/wbc_util.c
+++ b/source/nsswitch/libwbclient/wbc_util.c
@@ -197,12 +197,12 @@ wbcErr wbcDomainInfo(const char *domain, struct wbcDomainInfo **dinfo)
* @return #wbcErr
*
**/
-wbcErr wbcResolveWinsByName(const char *name, const char **ip)
+wbcErr wbcResolveWinsByName(const char *name, char **ip)
{
struct winbindd_request request;
struct winbindd_response response;
wbcErr wbc_status = WBC_ERR_UNKNOWN_FAILURE;
- const char *ipaddr;
+ char *ipaddr;
ZERO_STRUCT(request);
ZERO_STRUCT(response);
diff --git a/source/nsswitch/libwbclient/wbclient.h b/source/nsswitch/libwbclient/wbclient.h
index cf111ae4880..22b3f9e9e72 100644
--- a/source/nsswitch/libwbclient/wbclient.h
+++ b/source/nsswitch/libwbclient/wbclient.h
@@ -426,7 +426,7 @@ wbcErr wbcAuthenticateUserEx(const struct wbcAuthUserParams *params,
/*
* Resolve functions
*/
-wbcErr wbcResolveWinsByName(const char *name, const char **ip);
+wbcErr wbcResolveWinsByName(const char *name, char **ip);
wbcErr wbcResolveWinsByIP(const char *ip, const char **name);
/*
diff --git a/source/nsswitch/wbinfo.c b/source/nsswitch/wbinfo.c
index 83f58ebbd0a..0900ef54a7a 100644
--- a/source/nsswitch/wbinfo.c
+++ b/source/nsswitch/wbinfo.c
@@ -300,7 +300,7 @@ static bool wbinfo_get_userdomgroups(const char *user_sid_str)
static bool wbinfo_wins_byname(const char *name)
{
wbcErr wbc_status = WBC_ERR_UNKNOWN_FAILURE;
- const char *ip = NULL;
+ char *ip = NULL;
wbc_status = wbcResolveWinsByName(name, &ip);
if (!WBC_ERROR_IS_OK(wbc_status)) {