Home GnuPG
Diffusion GPGME 6e57379c8e37

core: Use better error code when using select with a too high fd.
6e57379c8e37Unpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

core: Use better error code when using select with a too high fd.

* src/posix-io.c (_gpgme_io_select): Return EMFILE instead of EBADF.

Also EBADF seem more correct, EMFILE (Too man open files) gives
a clearer message to the user that there are somehow too many files
open. The problem can be exhibited by running lots of threads,

We should eventually move to poll but that would be a large change and
so we better fix it with the planned migration of the I/O subsystem to
libgpgrt (currently known as libgpg-error).

  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Nov 10 2016, 7:49 PM
Parents
rMddd0a3cf90ac: tests: Reduce thread count in new thread tests
Branches
Unknown
Tags
Unknown

Event Timeline