diff options
author | NRK <nrk@disroot.org> | 2022-06-25 08:21:05 +0200 |
---|---|---|
committer | NRK <nrk@disroot.org> | 2022-06-25 08:21:05 +0200 |
commit | 658a935c04ba6dd1bfb370ad0e209046dd90402f (patch) | |
tree | c06c4f6c2830611a9afb195525b0cc71961073f0 /examples/image-info | |
parent | 9812d601c16fb243aac788abfeb9ea01a7870466 (diff) |
fix: potentially printing wrong error message (#321)
it's possible for the close() calls to override the errno resulting in
incorrect error message being printed.
call error() immediately to avoid such possibilities.
also refactor a couple conditions to avoid doing multiple checks.
Reviewed-on: https://codeberg.org/nsxiv/nsxiv/pulls/321
Reviewed-by: Berke Kocaoğlu <berke.kocaoglu@metu.edu.tr>
Diffstat (limited to 'examples/image-info')
0 files changed, 0 insertions, 0 deletions