diff options
author | Jakub Hrozek <jhrozek@redhat.com> | 2012-11-01 20:18:23 +0100 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2012-11-02 00:02:44 +0100 |
commit | a97f6203967b801d666ac686cdb7c76a7dfe55a9 (patch) | |
tree | d0e24cc267548c1179d9b14d785cd4a52739c1b3 /src/responder | |
parent | 31d97bce8f113276bf73c7d4349f720cd5edbcb8 (diff) | |
download | sssd2-a97f6203967b801d666ac686cdb7c76a7dfe55a9.tar.gz sssd2-a97f6203967b801d666ac686cdb7c76a7dfe55a9.tar.xz sssd2-a97f6203967b801d666ac686cdb7c76a7dfe55a9.zip |
PAM: Do not leak fd after SELinux context file is written
https://fedorahosted.org/sssd/ticket/1619
We don't close the fd when we write the selinux login file in the pam
responder. This results in a fd leak.
Diffstat (limited to 'src/responder')
-rw-r--r-- | src/responder/pam/pamsrv_cmd.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/responder/pam/pamsrv_cmd.c b/src/responder/pam/pamsrv_cmd.c index 2b20544d..bb0d8db3 100644 --- a/src/responder/pam/pamsrv_cmd.c +++ b/src/responder/pam/pamsrv_cmd.c @@ -443,6 +443,7 @@ static errno_t write_selinux_login_file(const char *username, char *string) } else { ret = EOK; } + close(fd); fd = -1; done: |