mirror of
https://git.openafs.org/openafs.git
synced 2025-01-19 07:20:11 +00:00
More pam warning cleanups - test_pam.c
Clear up a few more warnings in the pam code. The changes here are very similar to the ones in the previous patch and use the same configure test: - use PAM_CONST to conditionally declare pam_message as const - cast a few arguments to putenv, which expects a non-const pointer Change-Id: I6c98623c35f4453f34c1d48b8b7d6ff1bfbc1e0c Reviewed-on: http://gerrit.openafs.org/1116 Reviewed-by: Derrick Brashear <shadow@dementia.org> Tested-by: Derrick Brashear <shadow@dementia.org>
This commit is contained in:
parent
fdee40d8ea
commit
9f79dde2c8
@ -18,7 +18,7 @@
|
||||
#include <unistd.h>
|
||||
|
||||
|
||||
static int my_conv(int num_msg, struct pam_message **msg,
|
||||
static int my_conv(int num_msg, PAM_CONST struct pam_message **msg,
|
||||
struct pam_response **response, void *appdata_ptr);
|
||||
|
||||
|
||||
@ -97,8 +97,8 @@ main(int argc, char *argv[])
|
||||
}
|
||||
pam_end(pamh, PAM_SUCCESS);
|
||||
|
||||
putenv(new_envstring);
|
||||
putenv(new_homestring);
|
||||
putenv((char *)new_envstring);
|
||||
putenv((char *)new_homestring);
|
||||
chdir("/tmp");
|
||||
printf("Type exit to back out.\n");
|
||||
execl("/bin/csh", "/bin/csh", NULL);
|
||||
@ -106,10 +106,10 @@ main(int argc, char *argv[])
|
||||
|
||||
|
||||
static int
|
||||
my_conv(int num_msg, struct pam_message **msg, struct pam_response **response,
|
||||
my_conv(int num_msg, PAM_CONST struct pam_message **msg, struct pam_response **response,
|
||||
void *appdata_ptr)
|
||||
{
|
||||
struct pam_message *m;
|
||||
PAM_CONST struct pam_message *m;
|
||||
struct pam_response *r;
|
||||
char *p;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user