summaryrefslogtreecommitdiff
path: root/source3/libsmb
diff options
context:
space:
mode:
Diffstat (limited to 'source3/libsmb')
-rw-r--r--source3/libsmb/cli_dfs.c2
-rw-r--r--source3/libsmb/cli_lsarpc.c20
-rw-r--r--source3/libsmb/cli_samr.c34
-rw-r--r--source3/libsmb/cli_spoolss.c16
-rw-r--r--source3/libsmb/domain_client_validate.c10
-rw-r--r--source3/libsmb/errormap.c2
-rw-r--r--source3/libsmb/libsmbclient.c2
7 files changed, 43 insertions, 43 deletions
diff --git a/source3/libsmb/cli_dfs.c b/source3/libsmb/cli_dfs.c
index a16c76658f..ad36438ed8 100644
--- a/source3/libsmb/cli_dfs.c
+++ b/source3/libsmb/cli_dfs.c
@@ -66,7 +66,7 @@ uint32 cli_dfs_exist(struct cli_state *cli, TALLOC_CTX *mem_ctx,
*dfs_exists = (r.status == 1);
- result = NT_STATUS_NOPROBLEMO;
+ result = NT_STATUS_OK;
done:
prs_mem_free(&qbuf);
diff --git a/source3/libsmb/cli_lsarpc.c b/source3/libsmb/cli_lsarpc.c
index 8cf0817420..023f7f8dae 100644
--- a/source3/libsmb/cli_lsarpc.c
+++ b/source3/libsmb/cli_lsarpc.c
@@ -78,7 +78,7 @@ uint32 cli_lsa_open_policy(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*pol = r.pol;
}
@@ -136,7 +136,7 @@ uint32 cli_lsa_open_policy2(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*pol = r.pol;
}
@@ -184,7 +184,7 @@ uint32 cli_lsa_close(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*pol = r.pol;
}
@@ -242,7 +242,7 @@ uint32 cli_lsa_lookup_sids(struct cli_state *cli, TALLOC_CTX *mem_ctx,
result = r.status;
- if (result != NT_STATUS_NOPROBLEMO && result != 0x00000107 &&
+ if (result != NT_STATUS_OK && result != 0x00000107 &&
result != (0xC0000000 | NT_STATUS_NONE_MAPPED)) {
/* An actual error occured */
@@ -250,7 +250,7 @@ uint32 cli_lsa_lookup_sids(struct cli_state *cli, TALLOC_CTX *mem_ctx,
goto done;
}
- result = NT_STATUS_NOPROBLEMO;
+ result = NT_STATUS_OK;
/* Return output parameters */
@@ -347,7 +347,7 @@ uint32 cli_lsa_lookup_names(struct cli_state *cli, TALLOC_CTX *mem_ctx,
result = r.status;
- if (result != NT_STATUS_NOPROBLEMO &&
+ if (result != NT_STATUS_OK &&
result != (0xC0000000 | NT_STATUS_NONE_MAPPED)) {
/* An actual error occured */
@@ -355,7 +355,7 @@ uint32 cli_lsa_lookup_names(struct cli_state *cli, TALLOC_CTX *mem_ctx,
goto done;
}
- result = NT_STATUS_NOPROBLEMO;
+ result = NT_STATUS_OK;
/* Return output parameters */
@@ -441,7 +441,7 @@ uint32 cli_lsa_query_info_policy(struct cli_state *cli, TALLOC_CTX *mem_ctx,
goto done;
}
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -536,7 +536,7 @@ uint32 cli_lsa_enum_trust_dom(struct cli_state *cli, TALLOC_CTX *mem_ctx,
0x8000001a (NT_STATUS_UNABLE_TO_FREE_VM) so we ignore it and
pretend everything is OK. */
- if (result != NT_STATUS_NOPROBLEMO &&
+ if (result != NT_STATUS_OK &&
result != NT_STATUS_UNABLE_TO_FREE_VM) {
/* An actual error ocured */
@@ -544,7 +544,7 @@ uint32 cli_lsa_enum_trust_dom(struct cli_state *cli, TALLOC_CTX *mem_ctx,
goto done;
}
- result = NT_STATUS_NOPROBLEMO;
+ result = NT_STATUS_OK;
/* Return output parameters */
diff --git a/source3/libsmb/cli_samr.c b/source3/libsmb/cli_samr.c
index dee1baff02..123f5c116b 100644
--- a/source3/libsmb/cli_samr.c
+++ b/source3/libsmb/cli_samr.c
@@ -68,7 +68,7 @@ uint32 cli_samr_connect(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*connect_pol = r.connect_pol;
}
@@ -114,7 +114,7 @@ uint32 cli_samr_close(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*connect_pol = r.pol;
}
@@ -161,7 +161,7 @@ uint32 cli_samr_open_domain(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*domain_pol = r.domain_pol;
}
@@ -208,7 +208,7 @@ uint32 cli_samr_open_user(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*user_pol = r.user_pol;
}
@@ -255,7 +255,7 @@ uint32 cli_samr_open_group(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*group_pol = r.pol;
}
@@ -395,7 +395,7 @@ uint32 cli_samr_query_usergroups(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*num_groups = r.num_entries;
*gid = r.gid;
}
@@ -443,7 +443,7 @@ uint32 cli_samr_query_groupmem(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*num_mem = r.num_entries;
*rid = r.rid;
*attr = r.attr;
@@ -495,7 +495,7 @@ uint32 cli_samr_enum_dom_groups(struct cli_state *cli, TALLOC_CTX *mem_ctx,
result = r.status;
- if (result != NT_STATUS_NOPROBLEMO &&
+ if (result != NT_STATUS_OK &&
result != STATUS_MORE_ENTRIES) {
goto done;
}
@@ -569,7 +569,7 @@ uint32 cli_samr_query_aliasmem(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -629,7 +629,7 @@ uint32 cli_samr_open_alias(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*alias_pol = r.pol;
}
@@ -678,7 +678,7 @@ uint32 cli_samr_query_dom_info(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -731,7 +731,7 @@ uint32 cli_samr_query_dispinfo(struct cli_state *cli, TALLOC_CTX *mem_ctx,
result = r.status;
- if (result != NT_STATUS_NOPROBLEMO &&
+ if (result != NT_STATUS_OK &&
result != STATUS_MORE_ENTRIES) {
goto done;
}
@@ -791,7 +791,7 @@ uint32 cli_samr_lookup_rids(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -859,7 +859,7 @@ uint32 cli_samr_lookup_names(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -921,7 +921,7 @@ uint32 cli_samr_create_dom_user(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -977,7 +977,7 @@ uint32 cli_samr_set_userinfo(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
@@ -1024,7 +1024,7 @@ uint32 cli_samr_set_userinfo2(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) != NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) != NT_STATUS_OK) {
goto done;
}
diff --git a/source3/libsmb/cli_spoolss.c b/source3/libsmb/cli_spoolss.c
index 9c53912dff..b301de6448 100644
--- a/source3/libsmb/cli_spoolss.c
+++ b/source3/libsmb/cli_spoolss.c
@@ -84,7 +84,7 @@ uint32 cli_spoolss_open_printer_ex(
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*pol = r.handle;
}
@@ -137,7 +137,7 @@ uint32 cli_spoolss_close_printer(
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
*pol = r.handle;
}
@@ -429,7 +429,7 @@ uint32 cli_spoolss_enum_printers(
/* Return output parameters */
- if (((result=r.status) == NT_STATUS_NOPROBLEMO) && (*returned = r.returned))
+ if (((result=r.status) == NT_STATUS_OK) && (*returned = r.returned))
{
switch (level) {
@@ -505,7 +505,7 @@ uint32 cli_spoolss_enum_ports(
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO &&
+ if ((result = r.status) == NT_STATUS_OK &&
r.returned > 0) {
*returned = r.returned;
@@ -574,7 +574,7 @@ uint32 cli_spoolss_getprinter(
}
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO) {
+ if ((result = r.status) == NT_STATUS_OK) {
switch (level) {
case 0:
@@ -705,7 +705,7 @@ uint32 cli_spoolss_getprinterdriver (
}
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_NOPROBLEMO)
+ if ((result = r.status) == NT_STATUS_OK)
{
switch (level)
@@ -784,7 +784,7 @@ uint32 cli_spoolss_enumprinterdrivers (
}
/* Return output parameters */
- if (((result=r.status) == NT_STATUS_NOPROBLEMO) &&
+ if (((result=r.status) == NT_STATUS_OK) &&
(r.returned != 0))
{
*returned = r.returned;
@@ -865,7 +865,7 @@ uint32 cli_spoolss_getprinterdriverdir (
}
/* Return output parameters */
- if ((result=r.status) == NT_STATUS_NOPROBLEMO)
+ if ((result=r.status) == NT_STATUS_OK)
{
switch (level)
{
diff --git a/source3/libsmb/domain_client_validate.c b/source3/libsmb/domain_client_validate.c
index 5c56a815ef..69b5739b63 100644
--- a/source3/libsmb/domain_client_validate.c
+++ b/source3/libsmb/domain_client_validate.c
@@ -269,7 +269,7 @@ static BOOL find_connect_pdc(struct cli_state *pcli,
use it, otherwise figure out a server from the 'password server' param.
************************************************************************/
-uint32 domain_client_validate(const auth_usersupplied_info *user_info,
+NTSTATUS domain_client_validate(const auth_usersupplied_info *user_info,
auth_serversupplied_info *server_info,
char *server, unsigned char *trust_passwd,
time_t last_change_time)
@@ -280,7 +280,7 @@ uint32 domain_client_validate(const auth_usersupplied_info *user_info,
struct cli_state cli;
uint32 smb_uid_low;
BOOL connected_ok = False;
- uint32 status;
+ NTSTATUS status;
/*
* Check that the requested domain is not our own machine name.
@@ -325,14 +325,14 @@ uint32 domain_client_validate(const auth_usersupplied_info *user_info,
if ((status = cli_nt_login_network(&cli, user_info, smb_uid_low,
&ctr, &info3))
- != NT_STATUS_NOPROBLEMO) {
+ != NT_STATUS_OK) {
DEBUG(0,("domain_client_validate: unable to validate password "
"for user %s in domain %s to Domain controller %s. "
"Error was %s.\n", user_info->smb_username.str,
user_info->domain.str, remote_machine,
get_nt_error_msg(status)));
} else {
- status = NT_STATUS_NOPROBLEMO;
+ status = NT_STATUS_OK;
}
/*
@@ -346,7 +346,7 @@ uint32 domain_client_validate(const auth_usersupplied_info *user_info,
* send here. JRA.
*/
- if (status == NT_STATUS_NOPROBLMO) {
+ if (NT_STATUS_IS_OK(status)) {
if(cli_nt_logoff(&cli, &ctr) == False) {
DEBUG(0,("domain_client_validate: unable to log off user %s in domain \
%s to Domain controller %s. Error was %s.\n", user, domain, remote_machine, cli_errstr(&cli)));
diff --git a/source3/libsmb/errormap.c b/source3/libsmb/errormap.c
index 92a4b19847..a8baf025af 100644
--- a/source3/libsmb/errormap.c
+++ b/source3/libsmb/errormap.c
@@ -574,7 +574,7 @@ static struct {
{ERRDOS, ERRbadfile, NT_STATUS_NO_SUCH_FILE},
{ERRDOS, ERRbadpath, NT_STATUS_OBJECT_PATH_NOT_FOUND},
{ERRDOS, ERRnofids, NT_STATUS_TOO_MANY_OPENED_FILES},
- {ERRDOS, ERRnoaccess, NT_STATUS_INVALID_LOCK_SEQUENCE},
+ {ERRDOS, ERRnoaccess, NT_STATUS_ACCESS_DENIED},
{ERRDOS, ERRbadfid, NT_STATUS_INVALID_HANDLE},
{ERRDOS, ERRnomem, NT_STATUS_INSUFFICIENT_RESOURCES},
{ERRDOS, ERRbadaccess, NT_STATUS_INVALID_LOCK_SEQUENCE},
diff --git a/source3/libsmb/libsmbclient.c b/source3/libsmb/libsmbclient.c
index c0c586eceb..c3456bc4e7 100644
--- a/source3/libsmb/libsmbclient.c
+++ b/source3/libsmb/libsmbclient.c
@@ -207,7 +207,7 @@ int smbc_errno(struct cli_state *c)
DEBUG(3,("smbc_error %d %d (0x%x) -> %d\n",
(int)eclass, (int)ecode, (int)ecode, ret));
} else {
- uint32 status;
+ NTSTATUS status;
status = cli_nt_error(c);
ret = cli_errno_from_nt(status);