lslogins: call close() for usable FD [coverity scan]
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
665d79e793
commit
30e8df968f
|
@ -1654,7 +1654,9 @@ int main(int argc, char *argv[])
|
|||
|
||||
scols_unref_table(tb);
|
||||
tdestroy(ctl->usertree, free_user);
|
||||
close(ctl->lastlogin_fd);
|
||||
|
||||
if (ctl->lastlogin_fd >= 0)
|
||||
close(ctl->lastlogin_fd);
|
||||
free_ctl(ctl);
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
|
|
Loading…
Reference in New Issue