summaryrefslogtreecommitdiff
path: root/source3/pam_smbpass
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2006-05-06 20:05:43 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:16:53 -0500
commitfbc58eb455bd6f48725b0a817c28c8d5e02f69b4 (patch)
treeaf703c98b3493eb2efd96ee26a8d882ef9654554 /source3/pam_smbpass
parent5ab7e77bc7659a9707fb702b162fc4201f244c60 (diff)
downloadsamba-fbc58eb455bd6f48725b0a817c28c8d5e02f69b4.tar.gz
samba-fbc58eb455bd6f48725b0a817c28c8d5e02f69b4.tar.bz2
samba-fbc58eb455bd6f48725b0a817c28c8d5e02f69b4.zip
r15477: Committing parts of the patch Timur has submitted for bug 2961, as agreed upon
on irc. Thanks, Volker (This used to be commit 51b415d2306f8244d7449756e4fa873adfc8fbe7)
Diffstat (limited to 'source3/pam_smbpass')
-rw-r--r--source3/pam_smbpass/general.h4
-rw-r--r--source3/pam_smbpass/support.c8
2 files changed, 4 insertions, 8 deletions
diff --git a/source3/pam_smbpass/general.h b/source3/pam_smbpass/general.h
index 4f13d60131..f84c254444 100644
--- a/source3/pam_smbpass/general.h
+++ b/source3/pam_smbpass/general.h
@@ -50,10 +50,6 @@ typedef struct {
#define set(x,ctrl) (ctrl = ((ctrl)&smb_args[x].mask)|smb_args[x].flag)
#define unset(x,ctrl) (ctrl &= ~(smb_args[x].flag))
-#ifndef __linux__
-#define strncasecmp(s1,s2,n) StrnCaseCmp(s1,s2,n)
-#endif
-
/* the generic mask */
#define _ALL_ON_ (~0U)
diff --git a/source3/pam_smbpass/support.c b/source3/pam_smbpass/support.c
index c318a5c3ed..2ee43ffa1e 100644
--- a/source3/pam_smbpass/support.c
+++ b/source3/pam_smbpass/support.c
@@ -114,7 +114,7 @@
struct pam_response *resp;
pmsg[0] = &msg[0];
- msg[0].msg = text;
+ msg[0].msg = CONST_DISCARD(char *, text);
msg[0].msg_style = type;
resp = NULL;
@@ -515,7 +515,7 @@ int _smb_read_password( pam_handle_t * pamh, unsigned int ctrl,
if (comment != NULL && off(SMB__QUIET, ctrl)) {
pmsg[0] = &msg[0];
msg[0].msg_style = PAM_TEXT_INFO;
- msg[0].msg = comment;
+ msg[0].msg = CONST_DISCARD(char *, comment);
i = 1;
} else {
i = 0;
@@ -523,12 +523,12 @@ int _smb_read_password( pam_handle_t * pamh, unsigned int ctrl,
pmsg[i] = &msg[i];
msg[i].msg_style = PAM_PROMPT_ECHO_OFF;
- msg[i++].msg = prompt1;
+ msg[i++].msg = CONST_DISCARD(char *, prompt1);
if (prompt2 != NULL) {
pmsg[i] = &msg[i];
msg[i].msg_style = PAM_PROMPT_ECHO_OFF;
- msg[i++].msg = prompt2;
+ msg[i++].msg = CONST_DISCARD(char *, prompt2);
expect = 2;
} else
expect = 1;