Группа :: Система/Библиотеки
Пакет: gpgme
Главная Изменения Спек Патчи Загрузить Bugs and FR
Патч: gpgme-0.3.16-fix-select-status.patch
--- gpgme-0.3.16/gpgme/rungpg.c.fix-select-status 2002-11-26 00:04:52 +0300
+++ gpgme-0.3.16/gpgme/rungpg.c 2004-08-26 20:13:03 +0400
@@ -1100,6 +1100,22 @@ read_status (GpgObject gpg)
(gpg->cmd.linked_data, fds.fd);
}
while (fds.signaled);
+ /* After messing with the fd directly we must
+ remove it and add it again to clear the
+ possible outstanding ready condition,
+ otherwise the event loop might remember that
+ the fd was ready and call its callback, which
+ will block in read(). */
+ if (gpg->fd_data_map[gpg->cmd.linked_idx].tag)
+ {
+ struct fd_data_map_s *map =
+ &gpg->fd_data_map[gpg->cmd.linked_idx];
+ (*gpg->io_cbs.remove) (map->tag);
+ _gpgme_gpg_add_io_cb
+ (gpg, map->fd, 1,
+ _gpgme_data_inbound_handler,
+ map->data, &map->tag);
+ }
}
_gpgme_gpg_add_io_cb