summaryrefslogtreecommitdiff
path: root/source3/rpc_parse
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2000-08-01 18:32:34 +0000
committerJeremy Allison <jra@samba.org>2000-08-01 18:32:34 +0000
commit7f36df301e28dc8ca0e5bfadc109d6e907d9ba2b (patch)
tree97f6e250200b3ecfdb820da3bf38117f86ab4184 /source3/rpc_parse
parentd95777ac34f68a3525786103b9217f6397d9f1d4 (diff)
downloadsamba-7f36df301e28dc8ca0e5bfadc109d6e907d9ba2b.tar.gz
samba-7f36df301e28dc8ca0e5bfadc109d6e907d9ba2b.tar.bz2
samba-7f36df301e28dc8ca0e5bfadc109d6e907d9ba2b.zip
Tidyup removing many of the 0xC0000000 | NT_STATUS_XXX stuff (only need NT_STATUS_XXX).
Removed IS_BITS_xxx macros as they were just reproducing "C" syntax in a more obscure way. Jeremy. (This used to be commit c55bcec817f47d6162466b193d533c877194124a)
Diffstat (limited to 'source3/rpc_parse')
-rw-r--r--source3/rpc_parse/parse_rpc.c5
-rw-r--r--source3/rpc_parse/parse_samr.c4
-rw-r--r--source3/rpc_parse/parse_sec.c4
-rw-r--r--source3/rpc_parse/parse_spoolss.c6
4 files changed, 9 insertions, 10 deletions
diff --git a/source3/rpc_parse/parse_rpc.c b/source3/rpc_parse/parse_rpc.c
index af0569fd61..c40de10445 100644
--- a/source3/rpc_parse/parse_rpc.c
+++ b/source3/rpc_parse/parse_rpc.c
@@ -843,8 +843,7 @@ void init_rpc_auth_ntlmssp_resp(RPC_AUTH_NTLMSSP_RESP *rsp,
offset = 0x40;
- if (IS_BITS_SET_ALL(neg_flags, NTLMSSP_NEGOTIATE_UNICODE))
- {
+ if (neg_flags & NTLMSSP_NEGOTIATE_UNICODE) {
dom_len *= 2;
wks_len *= 2;
usr_len *= 2;
@@ -872,7 +871,7 @@ void init_rpc_auth_ntlmssp_resp(RPC_AUTH_NTLMSSP_RESP *rsp,
memcpy(rsp->lm_resp, lm_resp, 24);
memcpy(rsp->nt_resp, nt_resp, 24);
- if (IS_BITS_SET_ALL(neg_flags, NTLMSSP_NEGOTIATE_UNICODE)) {
+ if (neg_flags & NTLMSSP_NEGOTIATE_UNICODE) {
dos_struni2(rsp->domain, domain, sizeof(rsp->domain));
dos_struni2(rsp->user, user, sizeof(rsp->user));
dos_struni2(rsp->wks, wks, sizeof(rsp->wks));
diff --git a/source3/rpc_parse/parse_samr.c b/source3/rpc_parse/parse_samr.c
index 47e69670f7..58e65fa0af 100644
--- a/source3/rpc_parse/parse_samr.c
+++ b/source3/rpc_parse/parse_samr.c
@@ -1365,7 +1365,7 @@ void init_sam_info_2(SAM_INFO_2 *sam, uint32 acb_mask,
}
for (i = start_idx, entries_added = 0; i < num_sam_entries; i++) {
- if (IS_BITS_SET_ALL(pass[i].acb_info, acb_mask)) {
+ if ((pass[i].acb_info & acb_mask) == acb_mask) {
init_sam_entry2(&sam->sam[entries_added],
start_idx + entries_added + 1,
pass[i].uni_user_name.uni_str_len,
@@ -1451,7 +1451,7 @@ void init_sam_info_1(SAM_INFO_1 *sam, uint32 acb_mask,
for (i = 0, entries_added = 0;
i < num_sam_entries; i++) {
- if (IS_BITS_SET_ALL(pass[i].acb_info, acb_mask)) {
+ if ((pass[i].acb_info & acb_mask) == acb_mask) {
init_sam_entry1(&sam->sam[entries_added],
start_idx + entries_added + 1,
pass[i].uni_user_name.uni_str_len,
diff --git a/source3/rpc_parse/parse_sec.c b/source3/rpc_parse/parse_sec.c
index 4a7db6d7c2..00a1532470 100644
--- a/source3/rpc_parse/parse_sec.c
+++ b/source3/rpc_parse/parse_sec.c
@@ -510,7 +510,7 @@ BOOL sec_io_desc(char *desc, SEC_DESC **ppsd, prs_struct *ps, int depth)
max_offset = MAX(max_offset, prs_offset(ps));
- if (IS_BITS_SET_ALL(psd->type, SEC_DESC_SACL_PRESENT) && psd->off_sacl) {
+ if ((psd->type & SEC_DESC_SACL_PRESENT) && psd->off_sacl) {
if(!prs_set_offset(ps, old_offset + psd->off_sacl))
return False;
if(!sec_io_acl("sacl", &psd->sacl, ps, depth))
@@ -521,7 +521,7 @@ BOOL sec_io_desc(char *desc, SEC_DESC **ppsd, prs_struct *ps, int depth)
max_offset = MAX(max_offset, prs_offset(ps));
- if (IS_BITS_SET_ALL(psd->type, SEC_DESC_DACL_PRESENT) && psd->off_dacl != 0) {
+ if ((psd->type & SEC_DESC_DACL_PRESENT) && psd->off_dacl != 0) {
if(!prs_set_offset(ps, old_offset + psd->off_dacl))
return False;
if(!sec_io_acl("dacl", &psd->dacl, ps, depth))
diff --git a/source3/rpc_parse/parse_spoolss.c b/source3/rpc_parse/parse_spoolss.c
index d0a745d095..e618a81cc8 100644
--- a/source3/rpc_parse/parse_spoolss.c
+++ b/source3/rpc_parse/parse_spoolss.c
@@ -173,10 +173,10 @@ static BOOL smb_io_doc_info_container(char *desc, DOC_INFO_CONTAINER *cont, prs_
if(!prs_align(ps))
return False;
- if(!prs_uint32("level", ps, depth, &(cont->level)))
+ if(!prs_uint32("level", ps, depth, &cont->level))
return False;
- if(!smb_io_doc_info("",&(cont->docinfo), ps, depth))
+ if(!smb_io_doc_info("",&cont->docinfo, ps, depth))
return False;
return True;
@@ -234,7 +234,7 @@ static BOOL smb_io_notify_option_type_data(char *desc, SPOOL_NOTIFY_OPTION_TYPE
/* parse the option type data */
for(i=0;i<type->count2;i++)
- if(!prs_uint16("fields",ps,depth,&(type->fields[i])))
+ if(!prs_uint16("fields",ps,depth,&type->fields[i]))
return False;
return True;
}