diff options
author | des <des@FreeBSD.org> | 2003-02-08 20:18:25 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2003-02-08 20:18:25 +0000 |
commit | 08e4475303c898401b648428de379ac49d83aa72 (patch) | |
tree | 71f9e8b9d2785e2325fc4485b9b1c55f53aaee16 /contrib/openpam/lib/pam_chauthtok.c | |
parent | ead41a55fb5360e4a922a95a1b509a77591db405 (diff) | |
download | FreeBSD-src-08e4475303c898401b648428de379ac49d83aa72.zip FreeBSD-src-08e4475303c898401b648428de379ac49d83aa72.tar.gz |
MFP4: avoid side effects in macro arguments (#24823)
Diffstat (limited to 'contrib/openpam/lib/pam_chauthtok.c')
-rw-r--r-- | contrib/openpam/lib/pam_chauthtok.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/contrib/openpam/lib/pam_chauthtok.c b/contrib/openpam/lib/pam_chauthtok.c index 68fa483..74f2af3 100644 --- a/contrib/openpam/lib/pam_chauthtok.c +++ b/contrib/openpam/lib/pam_chauthtok.c @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $P4: //depot/projects/openpam/lib/pam_chauthtok.c#13 $ + * $P4: //depot/projects/openpam/lib/pam_chauthtok.c#14 $ */ #include <sys/param.h> @@ -51,19 +51,19 @@ int pam_chauthtok(pam_handle_t *pamh, int flags) { - int pam_err; + int r; ENTER(); if (flags & ~(PAM_SILENT|PAM_CHANGE_EXPIRED_AUTHTOK)) RETURNC(PAM_SYMBOL_ERR); - pam_err = openpam_dispatch(pamh, PAM_SM_CHAUTHTOK, + r = openpam_dispatch(pamh, PAM_SM_CHAUTHTOK, flags | PAM_PRELIM_CHECK); - if (pam_err == PAM_SUCCESS) - pam_err = openpam_dispatch(pamh, PAM_SM_CHAUTHTOK, + if (r == PAM_SUCCESS) + r = openpam_dispatch(pamh, PAM_SM_CHAUTHTOK, flags | PAM_UPDATE_AUTHTOK); pam_set_item(pamh, PAM_OLDAUTHTOK, NULL); pam_set_item(pamh, PAM_AUTHTOK, NULL); - RETURNC(pam_err); + RETURNC(r); } /* |