aborting (or finishing) pending operations in GPGME

Marcus Brinkmann Marcus.Brinkmann at ruhr-uni-bochum.de
Tue Jan 15 18:00:02 CET 2002

On Tue, Jan 15, 2002 at 04:54:01PM +0100, Werner Koch wrote:
> On Tue, 15 Jan 2002 16:25:16 +0100, Marcus Brinkmann said:
> > The stubs in posix-sema.c are empty.  This certainly needs to be fixed at
> Given that most software is not MT (for good reasons) I won't like to
> implement this unconditionally; it might be better to add a configure
> flag and build 2 vesions of the library - gpgme-config can then be
> used to figure out the needed one.
> Or should we provide an additional object file to shortcut the locking
> stuff?

I think our use of threading would not be too timing critical, so we can
probably make it so that the user has to enable locking at run time (and we
use a function table for the locking functions resp. their dummies).

Otherwise two versions of the library seems to be ok, too.

> > some time, but it will take some effort to go through gpgme and to add
> > proper locking.  That doesn't mean that you can't use it in a threaded
> There are not many places which need to be changed.  gpgme_wait()
> needs to be changed of course, the fail_on_pending_request macro and
> the stuff which fires up the backend.

It depends on what guarantees you want to make.  If you want to protect the
context as well, there is much more to be done.  If you require that one
context is not used by multiple threads at the same time, there is not too
much to do.


`Rhubarb is no Egyptian god.' Debian http://www.debian.org brinkmd at debian.org
Marcus Brinkmann              GNU    http://www.gnu.org    marcus at gnu.org
Marcus.Brinkmann at ruhr-uni-bochum.de

More information about the Gnupg-devel mailing list