diff options
author | Jeremy Allison <jra@samba.org> | 2005-06-24 20:25:18 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 10:58:00 -0500 |
commit | 19ca97a70f6b7b41d251eaa76e4d3c980c6eedff (patch) | |
tree | 18d7d81e2c1aa7cf9325899b7e8fc90b41c14c8b /source3/utils | |
parent | 8387af752f81e26f1c141f6053bf6d106f0af5eb (diff) | |
download | samba-19ca97a70f6b7b41d251eaa76e4d3c980c6eedff.tar.gz |
r7882: Looks like a large patch - but what it actually does is make Samba
safe for using our headers and linking with C++ modules. Stops us
from using C++ reserved keywords in our code.
Jeremy
(This used to be commit 9506b8e145982b1160a2f0aee5c9b7a54980940a)
Diffstat (limited to 'source3/utils')
-rw-r--r-- | source3/utils/net_rpc.c | 8 | ||||
-rw-r--r-- | source3/utils/net_rpc_samsync.c | 8 | ||||
-rw-r--r-- | source3/utils/nmblookup.c | 2 | ||||
-rw-r--r-- | source3/utils/ntlm_auth.c | 12 | ||||
-rw-r--r-- | source3/utils/pdbedit.c | 4 | ||||
-rw-r--r-- | source3/utils/profiles.c | 6 | ||||
-rw-r--r-- | source3/utils/smbcacls.c | 6 |
7 files changed, 23 insertions, 23 deletions
diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c index cf45216b6e8..2e8e6b64f8f 100644 --- a/source3/utils/net_rpc.c +++ b/source3/utils/net_rpc.c @@ -3684,7 +3684,7 @@ static BOOL get_user_sids(const char *domain, const char *user, fstrcpy(request.data.name.dom_name, domain); fstrcpy(request.data.name.name, user); - result = winbindd_request(WINBINDD_LOOKUPNAME, &request, &response); + result = winbindd_request_response(WINBINDD_LOOKUPNAME, &request, &response); if (result != NSS_STATUS_SUCCESS) { DEBUG(1, ("winbind could not find %s\n", full_name)); @@ -3706,7 +3706,7 @@ static BOOL get_user_sids(const char *domain, const char *user, fstrcpy(request.data.username, full_name); - result = winbindd_request(WINBINDD_GETGROUPS, &request, &response); + result = winbindd_request_response(WINBINDD_GETGROUPS, &request, &response); if (result != NSS_STATUS_SUCCESS) { DEBUG(1, ("winbind could not get groups of %s\n", full_name)); @@ -3725,7 +3725,7 @@ static BOOL get_user_sids(const char *domain, const char *user, sidrequest.data.gid = gid; - result = winbindd_request(WINBINDD_GID_TO_SID, + result = winbindd_request_response(WINBINDD_GID_TO_SID, &sidrequest, &sidresponse); if (result != NSS_STATUS_SUCCESS) { @@ -3769,7 +3769,7 @@ static BOOL get_user_tokens(int *num_tokens, struct user_token **user_tokens) ZERO_STRUCT(request); ZERO_STRUCT(response); - if (winbindd_request(WINBINDD_LIST_USERS, &request, &response) != + if (winbindd_request_response(WINBINDD_LIST_USERS, &request, &response) != NSS_STATUS_SUCCESS) return False; diff --git a/source3/utils/net_rpc_samsync.c b/source3/utils/net_rpc_samsync.c index 84872897fc5..ef12038d5ec 100644 --- a/source3/utils/net_rpc_samsync.c +++ b/source3/utils/net_rpc_samsync.c @@ -425,10 +425,10 @@ sam_account_from_delta(SAM_ACCOUNT *account, SAM_ACCOUNT_INFO *delta) /* Logon Hours */ if (delta->buf_logon_hrs.buffer) { - pstring old, new; - pdb_sethexhours(old, pdb_get_hours(account)); - pdb_sethexhours(new, delta->buf_logon_hrs.buffer); - if (!strequal(old, new)) + pstring oldstr, newstr; + pdb_sethexhours(oldstr, pdb_get_hours(account)); + pdb_sethexhours(newstr, delta->buf_logon_hrs.buffer); + if (!strequal(oldstr, newstr)) pdb_set_hours(account, (const char *)delta->buf_logon_hrs.buffer, PDB_CHANGED); } diff --git a/source3/utils/nmblookup.c b/source3/utils/nmblookup.c index 4ed42847867..d1d735f7f9e 100644 --- a/source3/utils/nmblookup.c +++ b/source3/utils/nmblookup.c @@ -101,7 +101,7 @@ static void do_node_status(int fd, const char *name, int type, struct in_addr ip { struct nmb_name nname; int count, i, j; - struct node_status *status; + NODE_STATUS_STRUCT *status; struct node_status_extra extra; fstring cleanname; diff --git a/source3/utils/ntlm_auth.c b/source3/utils/ntlm_auth.c index fcaad18ef60..6d5737aad4a 100644 --- a/source3/utils/ntlm_auth.c +++ b/source3/utils/ntlm_auth.c @@ -105,7 +105,7 @@ static char winbind_separator(void) /* Send off request */ - if (winbindd_request(WINBINDD_INFO, NULL, &response) != + if (winbindd_request_response(WINBINDD_INFO, NULL, &response) != NSS_STATUS_SUCCESS) { d_printf("could not obtain winbind separator!\n"); return *lp_winbind_separator(); @@ -135,7 +135,7 @@ const char *get_winbind_domain(void) /* Send off request */ - if (winbindd_request(WINBINDD_DOMAIN_NAME, NULL, &response) != + if (winbindd_request_response(WINBINDD_DOMAIN_NAME, NULL, &response) != NSS_STATUS_SUCCESS) { DEBUG(0, ("could not obtain winbind domain name!\n")); return lp_workgroup(); @@ -161,7 +161,7 @@ const char *get_winbind_netbios_name(void) /* Send off request */ - if (winbindd_request(WINBINDD_NETBIOS_NAME, NULL, &response) != + if (winbindd_request_response(WINBINDD_NETBIOS_NAME, NULL, &response) != NSS_STATUS_SUCCESS) { DEBUG(0, ("could not obtain winbind netbios name!\n")); return global_myname(); @@ -231,7 +231,7 @@ static BOOL get_require_membership_sid(void) { return False; } - if (winbindd_request(WINBINDD_LOOKUPNAME, &request, &response) != + if (winbindd_request_response(WINBINDD_LOOKUPNAME, &request, &response) != NSS_STATUS_SUCCESS) { DEBUG(0, ("Winbindd lookupname failed to resolve %s into a SID!\n", require_membership_of)); @@ -268,7 +268,7 @@ static BOOL check_plaintext_auth(const char *user, const char *pass, if (require_membership_of_sid) fstrcpy(request.data.auth.require_membership_of_sid, require_membership_of_sid); - result = winbindd_request(WINBINDD_PAM_AUTH, &request, &response); + result = winbindd_request_response(WINBINDD_PAM_AUTH, &request, &response); /* Display response */ @@ -348,7 +348,7 @@ NTSTATUS contact_winbind_auth_crap(const char *username, request.data.auth_crap.nt_resp_len = nt_response->length; } - result = winbindd_request(WINBINDD_PAM_AUTH_CRAP, &request, &response); + result = winbindd_request_response(WINBINDD_PAM_AUTH_CRAP, &request, &response); /* Display response */ diff --git a/source3/utils/pdbedit.c b/source3/utils/pdbedit.c index 88ec6b1f4fa..7c934cdb6c5 100644 --- a/source3/utils/pdbedit.c +++ b/source3/utils/pdbedit.c @@ -76,9 +76,9 @@ static int export_database (struct pdb_context *in, struct pdb_context while (NT_STATUS_IS_OK(in->pdb_getsampwent(in, user))) { DEBUG(4, ("Processing account %s\n", - user->private.username)); + user->private_u.username)); if (!username || - (strcmp(username, user->private.username) + (strcmp(username, user->private_u.username) == 0)) { out->pdb_add_sam_account(out, user); if (!NT_STATUS_IS_OK(pdb_reset_sam(user))) { diff --git a/source3/utils/profiles.c b/source3/utils/profiles.c index 0830d6b74b0..b718770ba34 100644 --- a/source3/utils/profiles.c +++ b/source3/utils/profiles.c @@ -395,7 +395,7 @@ static void print_sid(DOM_SID *sid); int verbose = 1; DOM_SID old_sid, new_sid; -int change = 0, new = 0; +int change = 0, new_val = 0; /* Compare two SIDs for equality */ static int my_sid_equal(DOM_SID *s1, DOM_SID *s2) @@ -562,7 +562,7 @@ int main(int argc, char *argv[]) break; case 'n': - new = 1; + new_val = 1; if (!get_sid(&new_sid, poptGetOptArg(pc))) { fprintf(stderr, "Argument to -n should be a SID in form of S-1-5-...\n"); poptPrintUsage(pc, stderr, 0); @@ -584,7 +584,7 @@ int main(int argc, char *argv[]) exit(1); } - if ((!change & new) || (change & !new)) { + if ((!change & new_val) || (change & !new_val)) { fprintf(stderr, "You must specify both -c and -n if one or the other is set!\n"); poptPrintUsage(pc, stderr, 0); exit(252); diff --git a/source3/utils/smbcacls.c b/source3/utils/smbcacls.c index 048ec8dc3ef..00000b5cfbe 100644 --- a/source3/utils/smbcacls.c +++ b/source3/utils/smbcacls.c @@ -318,7 +318,7 @@ static BOOL parse_ace(SEC_ACE *ace, char *str) /* add an ACE to a list of ACEs in a SEC_ACL */ static BOOL add_ace(SEC_ACL **the_acl, SEC_ACE *ace) { - SEC_ACL *new; + SEC_ACL *new_ace; SEC_ACE *aces; if (! *the_acl) { (*the_acl) = make_sec_acl(ctx, 3, 1, ace); @@ -328,9 +328,9 @@ static BOOL add_ace(SEC_ACL **the_acl, SEC_ACE *ace) aces = SMB_CALLOC_ARRAY(SEC_ACE, 1+(*the_acl)->num_aces); memcpy(aces, (*the_acl)->ace, (*the_acl)->num_aces * sizeof(SEC_ACE)); memcpy(aces+(*the_acl)->num_aces, ace, sizeof(SEC_ACE)); - new = make_sec_acl(ctx,(*the_acl)->revision,1+(*the_acl)->num_aces, aces); + new_ace = make_sec_acl(ctx,(*the_acl)->revision,1+(*the_acl)->num_aces, aces); SAFE_FREE(aces); - (*the_acl) = new; + (*the_acl) = new_ace; return True; } |