[gnutls-dev] Re: living without global variables
nmav at gnutls.org
Fri Dec 23 20:43:33 CET 2005
On Friday 23 December 2005 14:47, Simon Josefsson wrote:
> > The most serious way that these "variables" change during the
> > lifetime of the application is when a piece (module) of the
> > application does a gnutls_global_deinit(). That would blow up some
> > other module in the same application that happens to be using
> > gnutls.
> Yes. gnutls_global_deinit() should not be called if you want to
> continue to use the library. No other function modify that variable.
Note also that gnutls_global_init() and deinit() count the number of
times called. So for these variables to be freed the counter must be
zero. Thus most of these kind of problems are minimized.
More information about the Gnutls-devel