aboutsummaryrefslogtreecommitdiff
path: root/libpamc
diff options
context:
space:
mode:
authorChristian Göttsche <cgzones@googlemail.com>2024-01-04 17:46:46 +0100
committerChristian Göttsche <cgzones@googlemail.com>2024-01-04 17:46:46 +0100
commit4f0cf2eb43c73080789579f060a327d3d90fb0dc (patch)
treeb4208eb41546c3c86260ec55bf7239af55cadbd8 /libpamc
parentb1e446f59e50c03d88015b6cb078fb65bec7d77e (diff)
downloadpam-4f0cf2eb43c73080789579f060a327d3d90fb0dc.tar.gz
pam-4f0cf2eb43c73080789579f060a327d3d90fb0dc.tar.bz2
pam-4f0cf2eb43c73080789579f060a327d3d90fb0dc.zip
libpamc/test: fix assignment
Assign the error code instead of performing a no-op comparison. Reported by cppcheck.
Diffstat (limited to 'libpamc')
-rw-r--r--libpamc/test/modules/pam_secret.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libpamc/test/modules/pam_secret.c b/libpamc/test/modules/pam_secret.c
index 12215359..da607b1f 100644
--- a/libpamc/test/modules/pam_secret.c
+++ b/libpamc/test/modules/pam_secret.c
@@ -166,7 +166,7 @@ static int converse(pam_handle_t *pamh, struct ps_state_s *new)
retval = conv->conv(1, &msg_ptr, &single_reply, conv->appdata_ptr);
if (retval == PAM_SUCCESS) {
if ((single_reply == NULL) || (single_reply->resp == NULL)) {
- retval == PAM_CONV_ERR;
+ retval = PAM_CONV_ERR;
} else {
new->current_reply = (pamc_bp_t) single_reply->resp;
single_reply->resp = NULL;