summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerald W. Carter <jerry@samba.org>2008-04-17 17:49:53 +0200
committerKarolin Seeger <kseeger@samba.org>2008-04-21 08:40:42 +0200
commit594f977c8c4d74cfc8889d492ebbcc55b4fce976 (patch)
treef0c6b60e5ffa3b028c7a477995a8138f9cd43f98
parentbec4b4fbe56b7937c56d834cf30856c7ea10252d (diff)
downloadsamba-594f977c8c4d74cfc8889d492ebbcc55b4fce976.tar.gz
samba-594f977c8c4d74cfc8889d492ebbcc55b4fce976.tar.xz
samba-594f977c8c4d74cfc8889d492ebbcc55b4fce976.zip
Follow error code name convention in libwbclient.
s/WBC_INVALID_RESPONSE/WBC_ERR_INVALID_RESPONSE/ (cherry picked from commit d91ce012b0afb30cd22b373412d17de27c55ca86)
-rw-r--r--source/nsswitch/libwbclient/wbc_pam.c12
-rw-r--r--source/nsswitch/libwbclient/wbc_sid.c10
-rw-r--r--source/nsswitch/libwbclient/wbclient.c4
-rw-r--r--source/nsswitch/libwbclient/wbclient.h2
4 files changed, 14 insertions, 14 deletions
diff --git a/source/nsswitch/libwbclient/wbc_pam.c b/source/nsswitch/libwbclient/wbc_pam.c
index f6a355a413f..00e1f46fd9a 100644
--- a/source/nsswitch/libwbclient/wbc_pam.c
+++ b/source/nsswitch/libwbclient/wbc_pam.c
@@ -138,7 +138,7 @@ static wbcErr wbc_create_auth_info(TALLOC_CTX *mem_ctx,
p = (char *)resp->extra_data.data;
if (!p) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
@@ -149,7 +149,7 @@ static wbcErr wbc_create_auth_info(TALLOC_CTX *mem_ctx,
char *s = p;
char *e = strchr(p, '\n');
if (!e) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
e[0] = '\0';
@@ -157,7 +157,7 @@ static wbcErr wbc_create_auth_info(TALLOC_CTX *mem_ctx,
ret = sscanf(s, "0x%08X:0x%08X", &rid, &attrs);
if (ret != 2) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
@@ -173,7 +173,7 @@ static wbcErr wbc_create_auth_info(TALLOC_CTX *mem_ctx,
char *a;
char *e = strchr(p, '\n');
if (!e) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
e[0] = '\0';
@@ -181,7 +181,7 @@ static wbcErr wbc_create_auth_info(TALLOC_CTX *mem_ctx,
e = strchr(s, ':');
if (!e) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
e[0] = '\0';
@@ -190,7 +190,7 @@ static wbcErr wbc_create_auth_info(TALLOC_CTX *mem_ctx,
ret = sscanf(a, "0x%08X",
&attrs);
if (ret != 1) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
diff --git a/source/nsswitch/libwbclient/wbc_sid.c b/source/nsswitch/libwbclient/wbc_sid.c
index 6ef9f44c3be..de9b02822f5 100644
--- a/source/nsswitch/libwbclient/wbc_sid.c
+++ b/source/nsswitch/libwbclient/wbc_sid.c
@@ -372,21 +372,21 @@ wbcErr wbcLookupRids(struct wbcDomainSid *dom_sid,
char *q;
if (*p == '\0') {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
(*types)[i] = (enum wbcSidType)strtoul(p, &q, 10);
if (*q != ' ') {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
p = q+1;
if ((q = strchr(p, '\n')) == NULL) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
@@ -399,7 +399,7 @@ wbcErr wbcLookupRids(struct wbcDomainSid *dom_sid,
}
if (*p != '\0') {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
@@ -471,7 +471,7 @@ wbcErr wbcLookupUserSids(const struct wbcDomainSid *user_sid,
if (response.data.num_entries &&
!response.extra_data.data) {
- wbc_status = WBC_INVALID_RESPONSE;
+ wbc_status = WBC_ERR_INVALID_RESPONSE;
BAIL_ON_WBC_ERROR(wbc_status);
}
diff --git a/source/nsswitch/libwbclient/wbclient.c b/source/nsswitch/libwbclient/wbclient.c
index e17296283f0..ea34b729b04 100644
--- a/source/nsswitch/libwbclient/wbclient.c
+++ b/source/nsswitch/libwbclient/wbclient.c
@@ -106,8 +106,8 @@ const char *wbcErrorString(wbcErr error)
return "WBC_ERR_WINBIND_NOT_AVAILABLE";
case WBC_ERR_DOMAIN_NOT_FOUND:
return "WBC_ERR_DOMAIN_NOT_FOUND";
- case WBC_INVALID_RESPONSE:
- return "WBC_INVALID_RESPONSE";
+ case WBC_ERR_INVALID_RESPONSE:
+ return "WBC_ERR_INVALID_RESPONSE";
case WBC_ERR_NSS_ERROR:
return "WBC_ERR_NSS_ERROR";
case WBC_ERR_AUTH_ERROR:
diff --git a/source/nsswitch/libwbclient/wbclient.h b/source/nsswitch/libwbclient/wbclient.h
index b36b5bbe889..812751d9b53 100644
--- a/source/nsswitch/libwbclient/wbclient.h
+++ b/source/nsswitch/libwbclient/wbclient.h
@@ -40,7 +40,7 @@ enum _wbcErrType {
WBC_ERR_INVALID_PARAM, /**< An Invalid parameter was supplied **/
WBC_ERR_WINBIND_NOT_AVAILABLE, /**< Winbind daemon is not available **/
WBC_ERR_DOMAIN_NOT_FOUND, /**< Domain is not trusted or cannot be found **/
- WBC_INVALID_RESPONSE, /**< Winbind returned an invalid response **/
+ WBC_ERR_INVALID_RESPONSE, /**< Winbind returned an invalid response **/
WBC_ERR_NSS_ERROR, /**< NSS_STATUS error **/
WBC_ERR_AUTH_ERROR /**< Authentication failed **/
};