PAM: don't use global password buffer for conv struct
authorAlexander Barton <alex@barton.de>
Sat, 31 Dec 2011 17:06:17 +0000 (18:06 +0100)
committerAlexander Barton <alex@barton.de>
Sat, 31 Dec 2011 17:06:17 +0000 (18:06 +0100)
Use the pointer of the password of the client directly.
Eventually we can get rid of the global password again ...

src/ngircd/pam.c

index b28e866f42324d4b497f998ad34a8021205233c3..6382c594db0747f5872b7042cb553713d3abd4f1 100644 (file)
@@ -103,7 +103,7 @@ PAM_Authenticate(CLIENT *Client) {
        if (password)
                free(password);
        password = strdup(Client_Password(Client));
-       conv.appdata_ptr = password;
+       conv.appdata_ptr = Client_Password(Client);
 
        /* Initialize PAM */
        retval = pam_start("ngircd", Client_OrigUser(Client), &conv, &pam);