Don't unregister p11-kit PIN callback until vpninfo is finished with
authorDavid Woodhouse <David.Woodhouse@intel.com>
Sat, 9 Jun 2012 16:06:09 +0000 (17:06 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Sat, 9 Jun 2012 20:05:05 +0000 (21:05 +0100)
commitb682fb7986a5a2ad8daa90484f0da8b6e2a2e0a8
treeea2136dceccdfc5adc23c167839df1c6cf76c694
parent3249ec9ad09c088526f0e1ba2a489e709a32570a
Don't unregister p11-kit PIN callback until vpninfo is finished with

Unregistering in openconnect_close_https() meant that when we reconnect to
the server, we lose the PIN callback. And then when we connect again, if
GnuTLS is asking us for the PIN on every attempt to touch the key, we fail
because there's no PIN handler.

So add a 'final' flag to openconnect_close_https(). Use this to clean up
library.c::openconnect_close_https() a little, too.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
cstp.c
gnutls.c
http.c
library.c
openconnect-internal.h
openssl.c