summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
4d8a779)
The only caller currently checks if the result is non-zero,
so nothing changes there.
pam_handle_t *handle = NULL;
sigset_t ss, old_ss;
int pam_code = PAM_SUCCESS;
pam_handle_t *handle = NULL;
sigset_t ss, old_ss;
int pam_code = PAM_SUCCESS;
char **e = NULL;
bool close_session = false;
pid_t pam_pid = 0, parent_pid;
char **e = NULL;
bool close_session = false;
pid_t pam_pid = 0, parent_pid;
+ if (pam_code != PAM_SUCCESS)
+ err = -EPERM; /* PAM errors do not map to errno */
+ else
+ err = -errno;
+
if (handle) {
if (close_session)
pam_code = pam_close_session(handle, PAM_DATA_SILENT);
if (handle) {
if (close_session)
pam_code = pam_close_session(handle, PAM_DATA_SILENT);
kill(pam_pid, SIGCONT);
}
kill(pam_pid, SIGCONT);
}