aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorNIIBE Yutaka <[email protected]>2023-10-03 02:44:11 +0000
committerNIIBE Yutaka <[email protected]>2023-10-03 02:44:11 +0000
commit4206d89003d13af1385d5d2d957378cfc2c7fd4c (patch)
tree8b9e34d79cf161f423a81ac0c6f2bcb4ac7e5f8a /tests
parenttpm2d: Fix call to assuan_control. (diff)
downloadgnupg-4206d89003d13af1385d5d2d957378cfc2c7fd4c.tar.gz
gnupg-4206d89003d13af1385d5d2d957378cfc2c7fd4c.zip
tests:gpgscm: Fix process select loop.
* tests/gpgscm/ffi.c (do_process_spawn_io): Clear READ_FDSET in the loop. -- Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'tests')
-rw-r--r--tests/gpgscm/ffi.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/tests/gpgscm/ffi.c b/tests/gpgscm/ffi.c
index cac052138..36b0b98d2 100644
--- a/tests/gpgscm/ffi.c
+++ b/tests/gpgscm/ffi.c
@@ -1025,19 +1025,13 @@ do_process_spawn_io (scheme *sc, pointer args)
fd_set read_fdset;
ssize_t bytes_read;
- if (out_fd < 0)
- goto errout;
-
- if (err_fd < 0)
- goto errout;
-
- FD_ZERO (&read_fdset);
-
while (1)
{
int nfd;
int ret;
+ FD_ZERO (&read_fdset);
+
if (out_fd >= 0)
FD_SET (out_fd, &read_fdset);