summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2002-03-17 04:36:35 +0000
committerTim Potter <tpot@samba.org>2002-03-17 04:36:35 +0000
commitab13654dc9ac23872e4d1384e1c54e336f113009 (patch)
treece8b9a4b295bc256395b709b068eeb512c4936fb
parent0bb16f1d01a911aafe585fc558fbc473eddc4065 (diff)
downloadsamba-ab13654dc9ac23872e4d1384e1c54e336f113009.tar.gz
samba-ab13654dc9ac23872e4d1384e1c54e336f113009.tar.bz2
samba-ab13654dc9ac23872e4d1384e1c54e336f113009.zip
Renamed get_nt_error_msg() to nt_errstr().
(This used to be commit 1f007d3ed41c1b71a89fa6be7d173e67e927c302)
-rw-r--r--source3/auth/auth.c6
-rw-r--r--source3/auth/auth_domain.c4
-rw-r--r--source3/lib/util_seaccess.c2
-rw-r--r--source3/libsmb/cli_lsarpc.c4
-rw-r--r--source3/libsmb/cli_netlogon.c4
-rw-r--r--source3/libsmb/cli_wkssvc.c2
-rw-r--r--source3/libsmb/clierror.c2
-rw-r--r--source3/libsmb/libsmbclient.c2
-rw-r--r--source3/libsmb/nterr.c2
-rw-r--r--source3/libsmb/trust_passwd.c4
-rw-r--r--source3/nsswitch/winbindd_cm.c4
-rw-r--r--source3/nsswitch/winbindd_pam.c12
-rw-r--r--source3/passdb/pdb_interface.c2
-rw-r--r--source3/rpc_client/cli_netlogon.c10
-rw-r--r--source3/rpc_client/cli_reg.c30
-rw-r--r--source3/rpc_client/cli_samr.c22
-rw-r--r--source3/rpc_client/cli_spoolss.c26
-rw-r--r--source3/rpc_client/cli_srvsvc.c10
-rw-r--r--source3/rpc_client/cli_wkssvc.c2
-rw-r--r--source3/rpc_client/msrpc_spoolss.c2
-rw-r--r--source3/rpc_parse/parse_prs.c2
-rw-r--r--source3/rpc_server/srv_netlog_nt.c2
-rw-r--r--source3/rpc_server/srv_spoolss_nt.c2
-rw-r--r--source3/rpcclient/rpcclient.c6
-rw-r--r--source3/rpcclient/samsync.c2
-rw-r--r--source3/smbd/error.c2
-rw-r--r--source3/smbd/lanman.c2
-rw-r--r--source3/smbd/negprot.c2
-rw-r--r--source3/smbd/reply.c6
-rw-r--r--source3/torture/locktest.c4
-rw-r--r--source3/torture/scanner.c8
-rw-r--r--source3/torture/torture.c10
-rw-r--r--source3/utils/net.c4
-rw-r--r--source3/utils/net_rpc.c16
-rw-r--r--source3/utils/net_rpc_join.c6
35 files changed, 113 insertions, 113 deletions
diff --git a/source3/auth/auth.c b/source3/auth/auth.c
index e3af9dada6..c7b9fcc1d8 100644
--- a/source3/auth/auth.c
+++ b/source3/auth/auth.c
@@ -218,7 +218,7 @@ static NTSTATUS check_ntlm_password(const struct auth_context *auth_context,
auth_method->name, user_info->smb_name.str));
} else {
DEBUG(5, ("check_password: %s authentication for user [%s] FAILED with error %s\n",
- auth_method->name, user_info->smb_name.str, get_nt_error_msg(nt_status)));
+ auth_method->name, user_info->smb_name.str, nt_errstr(nt_status)));
}
talloc_destroy(mem_ctx);
@@ -248,7 +248,7 @@ static NTSTATUS check_ntlm_password(const struct auth_context *auth_context,
pdb_username));
} else {
DEBUG(3, ("check_password: PAM Account for user [%s] FAILED with error %s\n",
- pdb_username, get_nt_error_msg(nt_status)));
+ pdb_username, nt_errstr(nt_status)));
}
}
@@ -265,7 +265,7 @@ static NTSTATUS check_ntlm_password(const struct auth_context *auth_context,
if (!NT_STATUS_IS_OK(nt_status)) {
DEBUG(2, ("check_password: Authenticaion for user [%s] -> [%s] FAILED with error %s\n",
user_info->smb_name.str, user_info->internal_username.str,
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
ZERO_STRUCTP(server_info);
}
return nt_status;
diff --git a/source3/auth/auth_domain.c b/source3/auth/auth_domain.c
index b57bd2bfcc..5e3a4cd95b 100644
--- a/source3/auth/auth_domain.c
+++ b/source3/auth/auth_domain.c
@@ -134,7 +134,7 @@ machine %s. Error was : %s.\n", remote_machine, cli_errstr(*cli)));
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0,("connect_to_domain_password_server: unable to setup the PDC credentials to machine \
-%s. Error was : %s.\n", remote_machine, get_nt_error_msg(result)));
+%s. Error was : %s.\n", remote_machine, nt_errstr(result)));
cli_nt_session_close(*cli);
cli_ulogoff(*cli);
cli_shutdown(*cli);
@@ -319,7 +319,7 @@ static NTSTATUS domain_client_validate(TALLOC_CTX *mem_ctx,
"for user %s in domain %s to Domain controller %s. "
"Error was %s.\n", user_info->smb_name.str,
user_info->domain.str, cli->srv_name_slash,
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
} else {
char *dom_user;
diff --git a/source3/lib/util_seaccess.c b/source3/lib/util_seaccess.c
index 299b339ddf..8ed266aced 100644
--- a/source3/lib/util_seaccess.c
+++ b/source3/lib/util_seaccess.c
@@ -308,7 +308,7 @@ BOOL se_access_check(SEC_DESC *sd, NT_USER_TOKEN *token,
tmp_acc_desired = check_ace( ace, token, tmp_acc_desired, status);
if (NT_STATUS_V(*status)) {
*acc_granted = 0;
- DEBUG(5,("se_access_check: ACE %u denied with status %s.\n", (unsigned int)i, get_nt_error_msg(*status)));
+ DEBUG(5,("se_access_check: ACE %u denied with status %s.\n", (unsigned int)i, nt_errstr(*status)));
return False;
}
}
diff --git a/source3/libsmb/cli_lsarpc.c b/source3/libsmb/cli_lsarpc.c
index 249225d894..90b1cc8d69 100644
--- a/source3/libsmb/cli_lsarpc.c
+++ b/source3/libsmb/cli_lsarpc.c
@@ -1131,14 +1131,14 @@ Error was : %s.\n", remote_machine, cli_errstr(&cli) ));
result = cli_lsa_open_policy(&cli, cli.mem_ctx, True, SEC_RIGHTS_QUERY_VALUE, &lsa_pol);
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0, ("fetch_domain_sid: Error opening lsa policy handle. %s\n",
- get_nt_error_msg(result) ));
+ nt_errstr(result) ));
goto done;
}
result = cli_lsa_query_info_policy(&cli, cli.mem_ctx, &lsa_pol, 5, domain, psid);
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0, ("fetch_domain_sid: Error querying lsa policy handle. %s\n",
- get_nt_error_msg(result) ));
+ nt_errstr(result) ));
goto done;
}
diff --git a/source3/libsmb/cli_netlogon.c b/source3/libsmb/cli_netlogon.c
index 590f5f525e..125590b6d3 100644
--- a/source3/libsmb/cli_netlogon.c
+++ b/source3/libsmb/cli_netlogon.c
@@ -207,7 +207,7 @@ NTSTATUS new_cli_nt_setup_creds(struct cli_state *cli,
&srv_chal);
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0,("cli_nt_setup_creds: auth2 challenge failed %s\n",
- get_nt_error_msg(result)));
+ nt_errstr(result)));
}
return result;
@@ -648,7 +648,7 @@ NTSTATUS cli_net_srv_pwset(struct cli_state *cli, TALLOC_CTX *mem_ctx,
if (!NT_STATUS_IS_OK(r_s.status))
{
/* report error code */
- DEBUG(0,("cli_net_srv_pwset: %s\n", get_nt_error_msg(nt_status)));
+ DEBUG(0,("cli_net_srv_pwset: %s\n", nt_errstr(nt_status)));
goto done;
}
diff --git a/source3/libsmb/cli_wkssvc.c b/source3/libsmb/cli_wkssvc.c
index 391aee1782..2a84e6b698 100644
--- a/source3/libsmb/cli_wkssvc.c
+++ b/source3/libsmb/cli_wkssvc.c
@@ -99,7 +99,7 @@ NTSTATUS cli_wks_query_info(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* check returnet status code */
if (NT_STATUS_IS_ERR(r_o.status)) {
/* report the error */
- DEBUG(0,("WKS_R_QUERY_INFO: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("WKS_R_QUERY_INFO: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return r_o.status;
}
diff --git a/source3/libsmb/clierror.c b/source3/libsmb/clierror.c
index 13ea6b1997..591c04db22 100644
--- a/source3/libsmb/clierror.c
+++ b/source3/libsmb/clierror.c
@@ -103,7 +103,7 @@ char *cli_errstr(struct cli_state *cli)
if (flgs2 & FLAGS2_32_BIT_ERROR_CODES) {
NTSTATUS status = NT_STATUS(IVAL(cli->inbuf,smb_rcls));
- return get_nt_error_msg(status);
+ return nt_errstr(status);
}
cli_dos_error(cli, &errclass, &errnum);
diff --git a/source3/libsmb/libsmbclient.c b/source3/libsmb/libsmbclient.c
index eb2b7ae25b..237701b968 100644
--- a/source3/libsmb/libsmbclient.c
+++ b/source3/libsmb/libsmbclient.c
@@ -216,7 +216,7 @@ int smbc_errno(struct cli_state *c)
ret = cli_errno_from_nt(status);
DEBUG(3,("smbc errno %s -> %d\n",
- get_nt_error_msg(status), ret));
+ nt_errstr(status), ret));
}
return ret;
diff --git a/source3/libsmb/nterr.c b/source3/libsmb/nterr.c
index 4d13caba91..b74dde9b14 100644
--- a/source3/libsmb/nterr.c
+++ b/source3/libsmb/nterr.c
@@ -540,7 +540,7 @@ nt_err_code_struct nt_errs[] =
/*****************************************************************************
returns an NT error message. not amazingly helpful, but better than a number.
*****************************************************************************/
-char *get_nt_error_msg(NTSTATUS nt_code)
+char *nt_errstr(NTSTATUS nt_code)
{
static pstring msg;
int idx = 0;
diff --git a/source3/libsmb/trust_passwd.c b/source3/libsmb/trust_passwd.c
index 1f52ab3611..51ffa1dd95 100644
--- a/source3/libsmb/trust_passwd.c
+++ b/source3/libsmb/trust_passwd.c
@@ -40,7 +40,7 @@ static NTSTATUS just_change_the_password(struct cli_state *cli, TALLOC_CTX *mem_
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0,("just_change_the_password: unable to setup creds (%s)!\n",
- get_nt_error_msg(result)));
+ nt_errstr(result)));
return result;
}
@@ -48,7 +48,7 @@ static NTSTATUS just_change_the_password(struct cli_state *cli, TALLOC_CTX *mem_
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0,("just_change_the_password: unable to change password (%s)!\n",
- get_nt_error_msg(result)));
+ nt_errstr(result)));
}
return result;
}
diff --git a/source3/nsswitch/winbindd_cm.c b/source3/nsswitch/winbindd_cm.c
index 2c22ad46f2..fa31af9b9e 100644
--- a/source3/nsswitch/winbindd_cm.c
+++ b/source3/nsswitch/winbindd_cm.c
@@ -425,7 +425,7 @@ static NTSTATUS get_connection_from_cache(const char *domain, const char *pipe_n
if (!NT_STATUS_IS_OK(result = cm_open_connection(domain, pipe_name, conn))) {
DEBUG(3, ("Could not open a connection to %s for %s (%s)\n",
- domain, pipe_name, get_nt_error_msg(result)));
+ domain, pipe_name, nt_errstr(result)));
SAFE_FREE(conn);
return result;
}
@@ -773,7 +773,7 @@ NTSTATUS cm_get_netlogon_cli(char *domain, unsigned char *trust_passwd,
if (!NT_STATUS_IS_OK(result)) {
DEBUG(0, ("error connecting to domain password server: %s\n",
- get_nt_error_msg(result)));
+ nt_errstr(result)));
/* Hit the cache code again. This cleans out the old connection and gets a new one */
if (conn->cli->fd == -1) {
diff --git a/source3/nsswitch/winbindd_pam.c b/source3/nsswitch/winbindd_pam.c
index 9f6cf2d2ea..6a7afd2b3b 100644
--- a/source3/nsswitch/winbindd_pam.c
+++ b/source3/nsswitch/winbindd_pam.c
@@ -112,8 +112,8 @@ enum winbindd_result winbindd_pam_auth(struct winbindd_cli_state *state)
done:
state->response.data.auth.nt_status = NT_STATUS_V(result);
- fstrcpy(state->response.data.auth.nt_status_string, get_nt_error_msg(result));
- fstrcpy(state->response.data.auth.error_string, get_nt_error_msg(result));
+ fstrcpy(state->response.data.auth.nt_status_string, nt_errstr(result));
+ fstrcpy(state->response.data.auth.error_string, nt_errstr(result));
state->response.data.auth.pam_error = nt_status_to_pam(result);
DEBUG(NT_STATUS_IS_OK(result) ? 5 : 2, ("Plain-text authenticaion for user %s returned %s (PAM: %d)\n",
@@ -206,8 +206,8 @@ enum winbindd_result winbindd_pam_auth_crap(struct winbindd_cli_state *state)
done:
state->response.data.auth.nt_status = NT_STATUS_V(result);
- fstrcpy(state->response.data.auth.nt_status_string, get_nt_error_msg(result));
- fstrcpy(state->response.data.auth.error_string, get_nt_error_msg(result));
+ fstrcpy(state->response.data.auth.nt_status_string, nt_errstr(result));
+ fstrcpy(state->response.data.auth.error_string, nt_errstr(result));
state->response.data.auth.pam_error = nt_status_to_pam(result);
DEBUG(NT_STATUS_IS_OK(result) ? 5 : 2, ("NTLM CRAP authenticaion for user [%s]\\[%s] returned %s (PAM: %d)\n",
@@ -268,8 +268,8 @@ enum winbindd_result winbindd_pam_chauthtok(struct winbindd_cli_state *state)
done:
state->response.data.auth.nt_status = NT_STATUS_V(result);
- fstrcpy(state->response.data.auth.nt_status_string, get_nt_error_msg(result));
- fstrcpy(state->response.data.auth.error_string, get_nt_error_msg(result));
+ fstrcpy(state->response.data.auth.nt_status_string, nt_errstr(result));
+ fstrcpy(state->response.data.auth.error_string, nt_errstr(result));
state->response.data.auth.pam_error = nt_status_to_pam(result);
return NT_STATUS_IS_OK(result) ? WINBINDD_OK : WINBINDD_ERROR;
diff --git a/source3/passdb/pdb_interface.c b/source3/passdb/pdb_interface.c
index 953b5c4d2f..29f08cf46c 100644
--- a/source3/passdb/pdb_interface.c
+++ b/source3/passdb/pdb_interface.c
@@ -210,7 +210,7 @@ NTSTATUS make_pdb_context_name(struct pdb_context **context, const char *selecte
= builtin_pdb_init_functions[i].init(*context, &(*context)->pdb_selected, module_location))) {
DEBUG(5,("pdb backend %s has a valid init\n", selected));
} else {
- DEBUG(0,("pdb backend %s did not correctly init (error was %s)\n", selected, get_nt_error_msg(nt_status)));
+ DEBUG(0,("pdb backend %s did not correctly init (error was %s)\n", selected, nt_errstr(nt_status)));
(*context)->pdb_selected = NULL;
}
break;
diff --git a/source3/rpc_client/cli_netlogon.c b/source3/rpc_client/cli_netlogon.c
index 5b59e5b543..90c8a34c21 100644
--- a/source3/rpc_client/cli_netlogon.c
+++ b/source3/rpc_client/cli_netlogon.c
@@ -91,7 +91,7 @@ BOOL cli_net_logon_ctrl2(struct cli_state *cli, NTSTATUS status_level)
if (ok && r_l.status != 0)
{
/* report error code */
- DEBUG(0,("do_net_logon_ctrl2: Error %s\n", get_nt_error_msg(r_l.status)));
+ DEBUG(0,("do_net_logon_ctrl2: Error %s\n", nt_errstr(r_l.status)));
cli->nt_error = r_l.status;
ok = False;
}
@@ -153,7 +153,7 @@ NTSTATUS cli_net_auth2(struct cli_state *cli, uint16 sec_chan,
if (ok && !NT_STATUS_IS_OK(result))
{
/* report error code */
- DEBUG(0,("cli_net_auth2: Error %s\n", get_nt_error_msg(result)));
+ DEBUG(0,("cli_net_auth2: Error %s\n", nt_errstr(result)));
ok = False;
}
@@ -242,7 +242,7 @@ BOOL cli_net_req_chal(struct cli_state *cli, DOM_CHAL *clnt_chal, DOM_CHAL *srv_
if (ok && !NT_STATUS_IS_OK(r_c.status))
{
/* report error code */
- DEBUG(0,("cli_net_req_chal: Error %s\n", get_nt_error_msg(r_c.status)));
+ DEBUG(0,("cli_net_req_chal: Error %s\n", nt_errstr(r_c.status)));
ok = False;
}
@@ -332,7 +332,7 @@ static NTSTATUS cli_net_sam_logon_internal(struct cli_state *cli, NET_ID_INFO_CT
if (!NT_STATUS_IS_OK(retval)) {
/* report error code */
- DEBUG(0,("cli_net_sam_logon_internal: %s\n", get_nt_error_msg(r_s.status)));
+ DEBUG(0,("cli_net_sam_logon_internal: %s\n", nt_errstr(r_s.status)));
goto out;
}
@@ -447,7 +447,7 @@ BOOL cli_net_sam_logoff(struct cli_state *cli, NET_ID_INFO_CTR *ctr)
if (ok && !NT_STATUS_IS_OK(r_s.status))
{
/* report error code */
- DEBUG(0,("cli_net_sam_logoff: %s\n", get_nt_error_msg(r_s.status)));
+ DEBUG(0,("cli_net_sam_logoff: %s\n", nt_errstr(r_s.status)));
ok = False;
}
diff --git a/source3/rpc_client/cli_reg.c b/source3/rpc_client/cli_reg.c
index 64fd908314..628cd576a8 100644
--- a/source3/rpc_client/cli_reg.c
+++ b/source3/rpc_client/cli_reg.c
@@ -112,7 +112,7 @@ BOOL do_reg_open_hklm(struct cli_state *cli, uint16 unknown_0, uint32 level,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_OPEN_HKLM: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_OPEN_HKLM: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -173,7 +173,7 @@ BOOL do_reg_open_hku(struct cli_state *cli, uint16 unknown_0, uint32 level,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_OPEN_HKU: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_OPEN_HKU: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -235,7 +235,7 @@ BOOL do_reg_flush_key(struct cli_state *cli, POLICY_HND *hnd)
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_FLUSH_KEY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_FLUSH_KEY: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -297,7 +297,7 @@ BOOL do_reg_query_key(struct cli_state *cli, POLICY_HND *hnd,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_QUERY_KEY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_QUERY_KEY: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -365,7 +365,7 @@ BOOL do_reg_unknown_1a(struct cli_state *cli, POLICY_HND *hnd, uint32 *unk)
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_UNK_1A: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_UNK_1A: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -425,7 +425,7 @@ BOOL do_reg_query_info(struct cli_state *cli, POLICY_HND *hnd,
if ( r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_INFO: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_INFO: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -548,7 +548,7 @@ BOOL do_reg_get_key_sec(struct cli_state *cli, POLICY_HND *hnd, uint32 *sec_buf_
DEBUG(5,("sec_buf_size too small. use %d\n", *sec_buf_size));
} else if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_GET_KEY_SEC: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_GET_KEY_SEC: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
} else {
@@ -608,7 +608,7 @@ BOOL do_reg_delete_val(struct cli_state *cli, POLICY_HND *hnd, char *val_name)
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_DELETE_VALUE: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_DELETE_VALUE: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -665,7 +665,7 @@ BOOL do_reg_delete_key(struct cli_state *cli, POLICY_HND *hnd, char *key_name)
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_DELETE_KEY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_DELETE_KEY: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -743,7 +743,7 @@ BOOL do_reg_create_key(struct cli_state *cli, POLICY_HND *hnd,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_CREATE_KEY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_CREATE_KEY: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -805,7 +805,7 @@ BOOL do_reg_enum_key(struct cli_state *cli, POLICY_HND *hnd,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_ENUM_KEY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_ENUM_KEY: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -868,7 +868,7 @@ BOOL do_reg_create_val(struct cli_state *cli, POLICY_HND *hnd,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_CREATE_VALUE: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_CREATE_VALUE: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -929,7 +929,7 @@ BOOL do_reg_enum_val(struct cli_state *cli, POLICY_HND *hnd,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_ENUM_VALUE: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_ENUM_VALUE: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -991,7 +991,7 @@ BOOL do_reg_open_entry(struct cli_state *cli, POLICY_HND *hnd,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("REG_OPEN_ENTRY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("REG_OPEN_ENTRY: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
@@ -1051,7 +1051,7 @@ BOOL do_reg_close(struct cli_state *cli, POLICY_HND *hnd)
if (r_c.status != 0) {
/* report error code */
- DEBUG(0,("REG_CLOSE: %s\n", get_nt_error_msg(r_c.status)));
+ DEBUG(0,("REG_CLOSE: %s\n", nt_errstr(r_c.status)));
prs_mem_free(&rbuf);
return False;
}
diff --git a/source3/rpc_client/cli_samr.c b/source3/rpc_client/cli_samr.c
index 7b47cf425d..6467ae4fa9 100644
--- a/source3/rpc_client/cli_samr.c
+++ b/source3/rpc_client/cli_samr.c
@@ -140,7 +140,7 @@ BOOL do_samr_chgpasswd_user(struct cli_state *cli,
if (r_e.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_CHGPASSWD_USER: %s\n", get_nt_error_msg(r_e.status)));
+ DEBUG(0,("SAMR_R_CHGPASSWD_USER: %s\n", nt_errstr(r_e.status)));
prs_mem_free(&rdata);
return False;
}
@@ -197,7 +197,7 @@ BOOL do_samr_unknown_38(struct cli_state *cli, char *srv_name)
if (r_e.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_UNKNOWN_38: %s\n", get_nt_error_msg(r_e.status)));
+ DEBUG(0,("SAMR_R_UNKNOWN_38: %s\n", nt_errstr(r_e.status)));
prs_mem_free(&rdata);
return False;
}
@@ -255,7 +255,7 @@ BOOL do_samr_query_dom_info(struct cli_state *cli,
if (r_e.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_QUERY_DOMAIN_INFO: %s\n", get_nt_error_msg(r_e.status)));
+ DEBUG(0,("SAMR_R_QUERY_DOMAIN_INFO: %s\n", nt_errstr(r_e.status)));
prs_mem_free(&rdata);
return False;
}
@@ -323,7 +323,7 @@ BOOL do_samr_enum_dom_users(struct cli_state *cli,
if (r_e.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_ENUM_DOM_USERS: %s\n", get_nt_error_msg(r_e.status)));
+ DEBUG(0,("SAMR_R_ENUM_DOM_USERS: %s\n", nt_errstr(r_e.status)));
prs_mem_free(&rdata);
return False;
}
@@ -410,7 +410,7 @@ BOOL do_samr_connect(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_CONNECT: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SAMR_R_CONNECT: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -471,7 +471,7 @@ BOOL do_samr_open_user(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_OPEN_USER: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SAMR_R_OPEN_USER: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -533,7 +533,7 @@ BOOL do_samr_open_domain(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_OPEN_DOMAIN: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SAMR_R_OPEN_DOMAIN: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -600,7 +600,7 @@ BOOL do_samr_query_unknown_12(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_UNKNOWN_12: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SAMR_R_UNKNOWN_12: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -681,7 +681,7 @@ BOOL do_samr_query_usergroups(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_QUERY_USERGROUPS: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SAMR_R_QUERY_USERGROUPS: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -747,7 +747,7 @@ BOOL do_samr_query_userinfo(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_R_QUERY_USERINFO: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SAMR_R_QUERY_USERINFO: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -817,7 +817,7 @@ BOOL do_samr_close(struct cli_state *cli, POLICY_HND *hnd)
if (r_c.status != 0) {
/* report error code */
- DEBUG(0,("SAMR_CLOSE_HND: %s\n", get_nt_error_msg(r_c.status)));
+ DEBUG(0,("SAMR_CLOSE_HND: %s\n", nt_errstr(r_c.status)));
prs_mem_free(&rdata);
return False;
}
diff --git a/source3/rpc_client/cli_spoolss.c b/source3/rpc_client/cli_spoolss.c
index 55becc1982..ca01808f59 100644
--- a/source3/rpc_client/cli_spoolss.c
+++ b/source3/rpc_client/cli_spoolss.c
@@ -69,7 +69,7 @@ uint32 spoolss_enum_printerdrivers(const char *srv_name, const char *environment
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_ENUMPRINTERDRIVERS: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ENUMPRINTERDRIVERS: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
*returned=r_o.returned;
@@ -126,7 +126,7 @@ uint32 spoolss_enum_printers(uint32 flags, fstring srv_name, uint32 level,
if (r_o.status != NT_STATUS_OK)
{
/* report error code */
- DEBUG(3,("SPOOLSS_ENUMPRINTERS: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ENUMPRINTERS: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
@@ -185,7 +185,7 @@ uint32 spoolss_enum_ports(fstring srv_name, uint32 level,
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_ENUMPORTS: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ENUMPORTS: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
@@ -239,7 +239,7 @@ uint32 spoolss_enum_jobs(const POLICY_HND *hnd, uint32 firstjob, uint32 numofjob
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_ENUMJOBS: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ENUMJOBS: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
*returned=r_o.returned;
@@ -297,7 +297,7 @@ uint32 spoolss_enum_printerdata(const POLICY_HND *hnd, uint32 idx,
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_ENUMPRINTERDATA: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ENUMPRINTERDATA: %s\n", nt_errstr(r_o.status)));
}
*valuelen=r_o.valuesize;
@@ -357,7 +357,7 @@ uint32 spoolss_getprinter(const POLICY_HND *hnd, uint32 level,
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_GETPRINTER: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_GETPRINTER: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
}
@@ -410,7 +410,7 @@ uint32 spoolss_getprinterdriver(const POLICY_HND *hnd,
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_GETPRINTERDRIVER2: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_GETPRINTERDRIVER2: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
@@ -482,7 +482,7 @@ BOOL spoolss_open_printer_ex( const char *printername,
if (prs_offset(&rbuf)!= 0 && r_o.status != 0)
{
/* report error code */
- DEBUG(3,("SPOOLSS_OPENPRINTEREX: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_OPENPRINTEREX: %s\n", nt_errstr(r_o.status)));
p = False;
}
@@ -561,7 +561,7 @@ BOOL spoolss_addprinterex(POLICY_HND *hnd, const char* srv_name, PRINTER_INFO_2
if (r_o.status != NT_STATUS_OK)
{
/* report error code */
- DEBUG(3,("SPOOLSS_ADDPRINTEREX: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ADDPRINTEREX: %s\n", nt_errstr(r_o.status)));
valid_pol = False;
}
}
@@ -626,7 +626,7 @@ BOOL spoolss_closeprinter(POLICY_HND *hnd)
if (prs_offset(&rbuf)!=0 && r_c.status != 0)
{
/* report error code */
- DEBUG(3,("SPOOL_CLOSEPRINTER: %s\n", get_nt_error_msg(r_c.status)));
+ DEBUG(3,("SPOOL_CLOSEPRINTER: %s\n", nt_errstr(r_c.status)));
}
else
valid_close = True;
@@ -689,7 +689,7 @@ uint32 spoolss_getprinterdata(const POLICY_HND *hnd, const UNISTR2 *valuename,
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_GETPRINTERDATA: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_GETPRINTERDATA: %s\n", nt_errstr(r_o.status)));
}
*type=r_o.type;
@@ -748,7 +748,7 @@ uint32 spoolss_getprinterdriverdir(fstring srv_name, fstring env_name, uint32 le
{
if (r_o.status != NT_STATUS_OK)
{
- DEBUG(3,("SPOOLSS_GETPRINTERDRIVERDIRECTORY: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_GETPRINTERDRIVERDIRECTORY: %s\n", nt_errstr(r_o.status)));
}
*needed=r_o.needed;
@@ -800,7 +800,7 @@ uint32 spoolss_addprinterdriver(const char *srv_name, uint32 level, PRINTER_DRIV
if (r_o.status != NT_STATUS_OK)
{
/* report error code */
- DEBUG(3,("SPOOLSS_ADDPRINTERDRIVER: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(3,("SPOOLSS_ADDPRINTERDRIVER: %s\n", nt_errstr(r_o.status)));
}
}
}
diff --git a/source3/rpc_client/cli_srvsvc.c b/source3/rpc_client/cli_srvsvc.c
index 641fb4250d..024e711789 100644
--- a/source3/rpc_client/cli_srvsvc.c
+++ b/source3/rpc_client/cli_srvsvc.c
@@ -84,7 +84,7 @@ BOOL do_srv_net_srv_conn_enum(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SRV_R_NET_SRV_CONN_ENUM: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SRV_R_NET_SRV_CONN_ENUM: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -164,7 +164,7 @@ BOOL do_srv_net_srv_sess_enum(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SRV_R_NET_SRV_SESS_ENUM: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SRV_R_NET_SRV_SESS_ENUM: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -232,7 +232,7 @@ BOOL do_srv_net_srv_share_enum(struct cli_state *cli,
if (r_o->status != 0) {
/* report error code */
- DEBUG(0,("SRV_R_NET_SHARE_ENUM: %s\n", get_nt_error_msg(r_o->status)));
+ DEBUG(0,("SRV_R_NET_SHARE_ENUM: %s\n", nt_errstr(r_o->status)));
prs_mem_free(&rdata);
return False;
}
@@ -314,7 +314,7 @@ BOOL do_srv_net_srv_file_enum(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SRV_R_NET_FILE_ENUM: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SRV_R_NET_FILE_ENUM: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
@@ -381,7 +381,7 @@ BOOL do_srv_net_srv_get_info(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("SRV_R_NET_SRV_GET_INFO: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("SRV_R_NET_SRV_GET_INFO: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rdata);
return False;
}
diff --git a/source3/rpc_client/cli_wkssvc.c b/source3/rpc_client/cli_wkssvc.c
index 0dd5ba5bcd..788d60c56e 100644
--- a/source3/rpc_client/cli_wkssvc.c
+++ b/source3/rpc_client/cli_wkssvc.c
@@ -73,7 +73,7 @@ BOOL do_wks_query_info(struct cli_state *cli,
if (r_o.status != 0) {
/* report error code */
- DEBUG(0,("WKS_R_QUERY_INFO: %s\n", get_nt_error_msg(r_o.status)));
+ DEBUG(0,("WKS_R_QUERY_INFO: %s\n", nt_errstr(r_o.status)));
prs_mem_free(&rbuf);
return False;
}
diff --git a/source3/rpc_client/msrpc_spoolss.c b/source3/rpc_client/msrpc_spoolss.c
index 02a5694e8b..2267190d8e 100644
--- a/source3/rpc_client/msrpc_spoolss.c
+++ b/source3/rpc_client/msrpc_spoolss.c
@@ -249,7 +249,7 @@ BOOL msrpc_spoolss_enum_printers(char* srv_name, uint32 flags,
if (status!=NT_STATUS_OK)
{
- DEBUG(0,("spoolss_enum_printers: %s\n", get_nt_error_msg(status)));
+ DEBUG(0,("spoolss_enum_printers: %s\n", nt_errstr(status)));
if (mem_ctx)
talloc_destroy(mem_ctx);
return False;
diff --git a/source3/rpc_parse/parse_prs.c b/source3/rpc_parse/parse_prs.c
index 2deefd362a..5d06cf7a7e 100644
--- a/source3/rpc_parse/parse_prs.c
+++ b/source3/rpc_parse/parse_prs.c
@@ -603,7 +603,7 @@ BOOL prs_ntstatus(char *name, prs_struct *ps, int depth, NTSTATUS *status)
}
DEBUG(5,("%s%04x %s: %s\n", tab_depth(depth), ps->data_offset, name,
- get_nt_error_msg(*status)));
+ nt_errstr(*status)));
ps->data_offset += sizeof(uint32);
diff --git a/source3/rpc_server/srv_netlog_nt.c b/source3/rpc_server/srv_netlog_nt.c
index 92ebfd97c5..5b9c136253 100644
--- a/source3/rpc_server/srv_netlog_nt.c
+++ b/source3/rpc_server/srv_netlog_nt.c
@@ -634,7 +634,7 @@ NTSTATUS _net_sam_logon(pipes_struct *p, NET_Q_SAM_LOGON *q_u, NET_R_SAM_LOGON *
free_user_info(&user_info);
DEBUG(5, ("_net_sam_logon: check_password returned status %s\n",
- get_nt_error_msg(status)));
+ nt_errstr(status)));
/* Check account and password */
diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c
index a6c0f9368c..a861aa1905 100644
--- a/source3/rpc_server/srv_spoolss_nt.c
+++ b/source3/rpc_server/srv_spoolss_nt.c
@@ -698,7 +698,7 @@ static void send_spoolss_event_notification(PRINTER_MESSAGE_INFO *msg)
if (!NT_STATUS_IS_OK(result)) {
DEBUG(10,("send_spoolss_event_notification: Event notification failed [%s]\n",
- get_nt_error_msg(result)));
+ nt_errstr(result)));
}
}
}
diff --git a/source3/rpcclient/rpcclient.c b/source3/rpcclient/rpcclient.c
index 38242648aa..3c8ede6966 100644
--- a/source3/rpcclient/rpcclient.c
+++ b/source3/rpcclient/rpcclient.c
@@ -234,7 +234,7 @@ void fetch_machine_sid(struct cli_state *cli)
fprintf(stderr, "could not obtain sid for domain %s\n", cli->domain);
if (!NT_STATUS_IS_OK(result)) {
- fprintf(stderr, "error: %s\n", get_nt_error_msg(result));
+ fprintf(stderr, "error: %s\n", nt_errstr(result));
}
exit(1);
@@ -521,7 +521,7 @@ static NTSTATUS process_cmd(struct cli_state *cli, char *cmd)
}
if (!NT_STATUS_IS_OK(result)) {
- printf("result was %s\n", get_nt_error_msg(result));
+ printf("result was %s\n", nt_errstr(result));
}
return result;
@@ -711,7 +711,7 @@ static void usage(void)
password, strlen(password));
if (!NT_STATUS_IS_OK(nt_status)) {
- DEBUG(1,("Cannot connect to server. Error was %s\n", get_nt_error_msg(nt_status)));
+ DEBUG(1,("Cannot connect to server. Error was %s\n", nt_errstr(nt_status)));
return 1;
}
diff --git a/source3/rpcclient/samsync.c b/source3/rpcclient/samsync.c
index d09ae775ec..14f7ed8953 100644
--- a/source3/rpcclient/samsync.c
+++ b/source3/rpcclient/samsync.c
@@ -611,7 +611,7 @@ static struct cli_state *init_connection(struct cli_state *cli,
result = sam_repl(&cli, trust_passwd, low_serial);
if (!NT_STATUS_IS_OK(result)) {
- DEBUG(0, ("%s\n", get_nt_error_msg(result)));
+ DEBUG(0, ("%s\n", nt_errstr(result)));
return 1;
}
diff --git a/source3/smbd/error.c b/source3/smbd/error.c
index 92a7c11b15..2f993fb41e 100644
--- a/source3/smbd/error.c
+++ b/source3/smbd/error.c
@@ -107,7 +107,7 @@ int error_packet(char *outbuf,NTSTATUS ntstatus,
file, line,
(int)CVAL(outbuf,smb_com),
smb_fn_name(CVAL(outbuf,smb_com)),
- get_nt_error_msg(ntstatus)));
+ nt_errstr(ntstatus)));
return outsize;
}
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c
index a218a04962..666bbb5f61 100644
--- a/source3/smbd/lanman.c
+++ b/source3/smbd/lanman.c
@@ -1632,7 +1632,7 @@ static BOOL api_RNetShareEnum(connection_struct *conn,uint16 vuid, char *param,c
*rdata = REALLOC(*rdata,*rdata_len);
memset(*rdata,0,*rdata_len);
- p2 = (*rdata) + fixed_len; /* auxillery data (strings) will go here */
+ p2 = (*rdata) + fixed_len; /* auxiliary data (strings) will go here */
p = *rdata;
f_len = fixed_len;
s_len = string_len;
diff --git a/source3/smbd/negprot.c b/source3/smbd/negprot.c
index f4ed360845..18682e6c9f 100644
--- a/source3/smbd/negprot.c
+++ b/source3/smbd/negprot.c
@@ -41,7 +41,7 @@ static void get_challenge(char buff[8])
DEBUG(10, ("get challenge: creating negprot_global_auth_context\n"));
if (!NT_STATUS_IS_OK(nt_status = make_auth_context_subsystem(&negprot_global_auth_context))) {
- DEBUG(0, ("make_auth_context_subsystem returned %s", get_nt_error_msg(nt_status)));
+ DEBUG(0, ("make_auth_context_subsystem returned %s", nt_errstr(nt_status)));
smb_panic("cannot make_negprot_global_auth_context!\n");
}
DEBUG(10, ("get challenge: getting challenge\n"));
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index e72b6a7319..1b7db5f0a7 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -3120,7 +3120,7 @@ directory = %s, newname = %s, newname_last_component = %s, is_8_3 = %d\n",
}
error = map_nt_error_from_unix(errno);
DEBUG(3,("rename_internals: Error %s rename %s -> %s\n",
- get_nt_error_msg(error), directory,newname));
+ nt_errstr(error), directory,newname));
return error;
}
@@ -3129,7 +3129,7 @@ directory = %s, newname = %s, newname_last_component = %s, is_8_3 = %d\n",
if (!NT_STATUS_IS_OK(error)) {
DEBUG(3,("rename_internals: Error %s rename %s -> %s\n",
- get_nt_error_msg(error), directory,newname));
+ nt_errstr(error), directory,newname));
return error;
}
@@ -3161,7 +3161,7 @@ directory = %s, newname = %s, newname_last_component = %s, is_8_3 = %d\n",
error = map_nt_error_from_unix(errno);
DEBUG(3,("rename_internals: Error %s rename %s -> %s\n",
- get_nt_error_msg(error), directory,newname));
+ nt_errstr(error), directory,newname));
return error;
} else {
diff --git a/source3/torture/locktest.c b/source3/torture/locktest.c
index 08a9e74269..c34b4c1ad2 100644
--- a/source3/torture/locktest.c
+++ b/source3/torture/locktest.c
@@ -299,7 +299,7 @@ static BOOL test_one(struct cli_state *cli[NSERVERS][NCONNECTIONS],
conn, f,
(double)start, (double)len,
op==READ_LOCK?"READ_LOCK":"WRITE_LOCK",
- get_nt_error_msg(status[0]), get_nt_error_msg(status[1]));
+ nt_errstr(status[0]), nt_errstr(status[1]));
}
if (showall || !NT_STATUS_EQUAL(status[0],status[1])) show_locks();
if (!NT_STATUS_EQUAL(status[0],status[1])) return False;
@@ -318,7 +318,7 @@ static BOOL test_one(struct cli_state *cli[NSERVERS][NCONNECTIONS],
printf("unlock conn=%u f=%u range=%.0f(%.0f) -> %s:%s\n",
conn, f,
(double)start, (double)len,
- get_nt_error_msg(status[0]), get_nt_error_msg(status[1]));
+ nt_errstr(status[0]), nt_errstr(status[1]));
}
if (showall || !NT_STATUS_EQUAL(status[0],status[1])) show_locks();
if (!hide_unlock_fails && !NT_STATUS_EQUAL(status[0],status[1]))
diff --git a/source3/torture/scanner.c b/source3/torture/scanner.c
index 69c2bfe72f..4f4164ea33 100644
--- a/source3/torture/scanner.c
+++ b/source3/torture/scanner.c
@@ -40,7 +40,7 @@ static void trans2_check_hit(char *format, int op, int level, NTSTATUS status)
}
#if VERBOSE
printf("possible %s hit op=%3d level=%5d status=%s\n",
- format, op, level, get_nt_error_msg(status));
+ format, op, level, nt_errstr(status));
#endif
}
@@ -89,7 +89,7 @@ static NTSTATUS try_trans2_len(struct cli_state *cli,
ret = try_trans2(cli, op, param, data, param_len,
sizeof(pstring), rparam_len, rdata_len);
#if VERBOSE
- printf("op=%d level=%d ret=%s\n", op, level, get_nt_error_msg(ret));
+ printf("op=%d level=%d ret=%s\n", op, level, nt_errstr(ret));
#endif
if (!NT_STATUS_IS_OK(ret)) return ret;
@@ -244,7 +244,7 @@ static void nttrans_check_hit(char *format, int op, int level, NTSTATUS status)
}
#if VERBOSE
printf("possible %s hit op=%3d level=%5d status=%s\n",
- format, op, level, get_nt_error_msg(status));
+ format, op, level, nt_errstr(status));
#endif
}
@@ -291,7 +291,7 @@ static NTSTATUS try_nttrans_len(struct cli_state *cli,
ret = try_nttrans(cli, op, param, data, param_len,
sizeof(pstring), rparam_len, rdata_len);
#if VERBOSE
- printf("op=%d level=%d ret=%s\n", op, level, get_nt_error_msg(ret));
+ printf("op=%d level=%d ret=%s\n", op, level, nt_errstr(ret));
#endif
if (!NT_STATUS_IS_OK(ret)) return ret;
diff --git a/source3/torture/torture.c b/source3/torture/torture.c
index cb9685f6b9..cb06457573 100644
--- a/source3/torture/torture.c
+++ b/source3/torture/torture.c
@@ -187,7 +187,7 @@ static BOOL check_error(int line, struct cli_state *c,
printf("unexpected error code class=%d code=%d\n",
(int)class, (int)num);
printf(" expected %d/%d %s (line=%d)\n",
- (int)eclass, (int)ecode, get_nt_error_msg(nterr), line);
+ (int)eclass, (int)ecode, nt_errstr(nterr), line);
return False;
}
@@ -199,8 +199,8 @@ static BOOL check_error(int line, struct cli_state *c,
status = cli_nt_error(c);
if (NT_STATUS_V(nterr) != NT_STATUS_V(status)) {
- printf("unexpected error code %s\n", get_nt_error_msg(status));
- printf(" expected %s (line=%d)\n", get_nt_error_msg(nterr), line);
+ printf("unexpected error code %s\n", nt_errstr(status));
+ printf(" expected %s (line=%d)\n", nt_errstr(nterr), line);
return False;
}
}
@@ -1520,12 +1520,12 @@ static BOOL run_locktest6(int dummy)
fnum = cli_open(&cli, fname[i], O_RDWR|O_CREAT|O_EXCL, DENY_NONE);
status = cli_locktype(&cli, fnum, 0, 8, 0, LOCKING_ANDX_CHANGE_LOCKTYPE);
cli_close(&cli, fnum);
- printf("CHANGE_LOCKTYPE gave %s\n", get_nt_error_msg(status));
+ printf("CHANGE_LOCKTYPE gave %s\n", nt_errstr(status));
fnum = cli_open(&cli, fname[i], O_RDWR, DENY_NONE);
status = cli_locktype(&cli, fnum, 0, 8, 0, LOCKING_ANDX_CANCEL_LOCK);
cli_close(&cli, fnum);
- printf("CANCEL_LOCK gave %s\n", get_nt_error_msg(status));
+ printf("CANCEL_LOCK gave %s\n", nt_errstr(status));
cli_unlink(&cli, fname[i]);
}
diff --git a/source3/utils/net.c b/source3/utils/net.c
index 109807851a..376b3ddbfd 100644
--- a/source3/utils/net.c
+++ b/source3/utils/net.c
@@ -147,7 +147,7 @@ NTSTATUS connect_to_ipc(struct cli_state **c, struct in_addr *server_ip,
return nt_status;
} else {
DEBUG(0,("Cannot connect to server. Error was %s\n",
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
/* Display a nicer message depending on the result */
@@ -176,7 +176,7 @@ NTSTATUS connect_to_ipc_anonymous(struct cli_state **c,
if (NT_STATUS_IS_OK(nt_status)) {
return nt_status;
} else {
- DEBUG(0,("Cannot connect to server (anonymously). Error was %s\n", get_nt_error_msg(nt_status)));
+ DEBUG(0,("Cannot connect to server (anonymously). Error was %s\n", nt_errstr(nt_status)));
return nt_status;
}
}
diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c
index dd8848bb73..6200d6f914 100644
--- a/source3/utils/net_rpc.c
+++ b/source3/utils/net_rpc.c
@@ -96,7 +96,7 @@ static DOM_SID *net_get_remote_domain_sid(struct cli_state *cli)
fprintf(stderr, "could not obtain sid for domain %s\n", cli->domain);
if (!NT_STATUS_IS_OK(result)) {
- fprintf(stderr, "error: %s\n", get_nt_error_msg(result));
+ fprintf(stderr, "error: %s\n", nt_errstr(result));
}
exit(1);
@@ -144,7 +144,7 @@ static int run_rpc_command(const char *pipe_name, int conn_flags,
nt_status = fn(domain_sid, cli, mem_ctx, argc, argv);
if (!NT_STATUS_IS_OK(nt_status)) {
- DEBUG(0, ("rpc command function failed! (%s)\n", get_nt_error_msg(nt_status)));
+ DEBUG(0, ("rpc command function failed! (%s)\n", nt_errstr(nt_status)));
} else {
DEBUG(5, ("rpc command function succedded\n"));
}
@@ -361,7 +361,7 @@ static NTSTATUS rpc_user_add_internals(const DOM_SID *domain_sid, struct cli_sta
done:
if (!NT_STATUS_IS_OK(result)) {
d_printf("Failed to add user %s - %s\n", acct_name,
- get_nt_error_msg(result));
+ nt_errstr(result));
} else {
d_printf("Added user %s\n", acct_name);
}
@@ -724,7 +724,7 @@ static int rpc_trustdom_establish(int argc, const char **argv) {
/* Is it trusting domain account for sure ? */
DEBUG(0, ("Couldn't verify trusting domain account. Error was %s\n",
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
return -1;
}
@@ -736,7 +736,7 @@ static int rpc_trustdom_establish(int argc, const char **argv) {
if (NT_STATUS_IS_ERR(nt_status)) {
DEBUG(0, ("Couldn't connect to domain %s controller. Error was %s.\n",
- domain_name, get_nt_error_msg(nt_status)));
+ domain_name, nt_errstr(nt_status)));
}
/*
@@ -803,7 +803,7 @@ static int rpc_trustdom_establish(int argc, const char **argv) {
&connect_hnd);
if (NT_STATUS_IS_ERR(nt_status)) {
DEBUG(0, ("Couldn't open policy handle. Error was %s\n",
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
return -1;
}
@@ -813,7 +813,7 @@ static int rpc_trustdom_establish(int argc, const char **argv) {
5 /* info level */, domain_name, &domain_sid);
if (NT_STATUS_IS_ERR(nt_status)) {
DEBUG(0, ("LSA Query Info failed. Returned error was %s\n",
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
return -1;
}
@@ -828,7 +828,7 @@ static int rpc_trustdom_establish(int argc, const char **argv) {
nt_status = cli_lsa_close(cli, mem_ctx, &connect_hnd);
if (NT_STATUS_IS_ERR(nt_status)) {
DEBUG(0, ("Couldn't close LSA pipe. Error was %s\n",
- get_nt_error_msg(nt_status)));
+ nt_errstr(nt_status)));
return -1;
}
diff --git a/source3/utils/net_rpc_join.c b/source3/utils/net_rpc_join.c
index a88292492a..a2c0614a50 100644
--- a/source3/utils/net_rpc_join.c
+++ b/source3/utils/net_rpc_join.c
@@ -25,7 +25,7 @@
#define CHECK_RPC_ERR(rpc, msg) \
if (!NT_STATUS_IS_OK(result = rpc)) { \
- DEBUG(0, (msg ": %s\n", get_nt_error_msg(result))); \
+ DEBUG(0, (msg ": %s\n", nt_errstr(result))); \
goto done; \
}
@@ -169,7 +169,7 @@ int net_rpc_join_newstyle(int argc, const char **argv)
1, &names, &num_rids,
&user_rids, &name_types),
("error looking up rid for user %s: %s\n",
- acct_name, get_nt_error_msg(result)));
+ acct_name, nt_errstr(result)));
if (name_types[0] != SID_NAME_USER) {
DEBUG(0, ("%s is not a user account\n", acct_name));
@@ -185,7 +185,7 @@ int net_rpc_join_newstyle(int argc, const char **argv)
SEC_RIGHTS_MAXIMUM_ALLOWED,
user_rid, &user_pol),
("could not re-open existing user %s: %s\n",
- acct_name, get_nt_error_msg(result)));
+ acct_name, nt_errstr(result)));
/* Create a random machine account password */