diff options
| author | Eli Zaretskii | 2017-11-05 17:26:36 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2017-11-05 17:26:36 +0200 |
| commit | c572e1f329583d40a6ae1a6cf493aba4a58c08e4 (patch) | |
| tree | efef82da71ae59786a6530814ceba501eb3f6d41 | |
| parent | a2cc6d74c5b94633e7fc044765e0ef40a8d63f50 (diff) | |
| download | emacs-c572e1f329583d40a6ae1a6cf493aba4a58c08e4.tar.gz emacs-c572e1f329583d40a6ae1a6cf493aba4a58c08e4.zip | |
Return non-nil from gnutls-available-p under GnuTLS 2.x
* doc/misc/emacs-gnutls.texi (Help For Users): Update the
documentation of 'gnutls-available-p'.
* etc/NEWS (GnuTLS): Mention the change in the value returned by
'gnutls-available-p'.
* src/gnutls.c (Fgnutls_available_p): Return non-nil when GnuTLS
2.x is available. (Bug#29147)
| -rw-r--r-- | doc/misc/emacs-gnutls.texi | 6 | ||||
| -rw-r--r-- | etc/NEWS | 4 | ||||
| -rw-r--r-- | src/gnutls.c | 2 |
3 files changed, 11 insertions, 1 deletions
diff --git a/doc/misc/emacs-gnutls.texi b/doc/misc/emacs-gnutls.texi index 0ad48b0b9ec..92846a924c5 100644 --- a/doc/misc/emacs-gnutls.texi +++ b/doc/misc/emacs-gnutls.texi | |||
| @@ -94,7 +94,11 @@ There's one way to find out if GnuTLS is available, by calling | |||
| 94 | Zaretskii) in the same directory as Emacs, you should be OK. | 94 | Zaretskii) in the same directory as Emacs, you should be OK. |
| 95 | 95 | ||
| 96 | @defun gnutls-available-p | 96 | @defun gnutls-available-p |
| 97 | This function returns @code{t} if GnuTLS is available in this instance of Emacs. | 97 | This function returns non-@code{nil} if GnuTLS is available in this |
| 98 | instance of Emacs, @code{nil} otherwise. If GnuTLS is available, the | ||
| 99 | value is a list of GnuTLS capabilities supported by the installed | ||
| 100 | GnuTLS library, which depends on the library version. The meaning of | ||
| 101 | the capabilities is documented in the doc string of this function. | ||
| 98 | @end defun | 102 | @end defun |
| 99 | 103 | ||
| 100 | Oh, but sometimes things go wrong. Budgets aren't balanced, | 104 | Oh, but sometimes things go wrong. Budgets aren't balanced, |
| @@ -1536,6 +1536,10 @@ and 'gnutls-symmetric-decrypt'. | |||
| 1536 | See the node "(elisp) GnuTLS Cryptography" in the ELisp manual for details. | 1536 | See the node "(elisp) GnuTLS Cryptography" in the ELisp manual for details. |
| 1537 | 1537 | ||
| 1538 | +++ | 1538 | +++ |
| 1539 | ** The function 'gnutls-available-p' now returns a list of capabilities | ||
| 1540 | supported by the GnuTLS library used by Emacs. | ||
| 1541 | |||
| 1542 | +++ | ||
| 1539 | ** Emacs now supports records for user-defined types, via the new | 1543 | ** Emacs now supports records for user-defined types, via the new |
| 1540 | functions 'make-record', 'record', and 'recordp'. Records are now | 1544 | functions 'make-record', 'record', and 'recordp'. Records are now |
| 1541 | used internally to represent cl-defstruct and defclass instances, for | 1545 | used internally to represent cl-defstruct and defclass instances, for |
diff --git a/src/gnutls.c b/src/gnutls.c index 36f65c4acb3..85cebd0e1c6 100644 --- a/src/gnutls.c +++ b/src/gnutls.c | |||
| @@ -2422,6 +2422,8 @@ GnuTLS AEAD ciphers : the list will contain `AEAD-ciphers'. */) | |||
| 2422 | 2422 | ||
| 2423 | #ifdef HAVE_GNUTLS | 2423 | #ifdef HAVE_GNUTLS |
| 2424 | 2424 | ||
| 2425 | capabilities = Fcons (intern("gnutls"), capabilities); | ||
| 2426 | |||
| 2425 | # ifdef HAVE_GNUTLS3 | 2427 | # ifdef HAVE_GNUTLS3 |
| 2426 | capabilities = Fcons (intern("gnutls3"), capabilities); | 2428 | capabilities = Fcons (intern("gnutls3"), capabilities); |
| 2427 | capabilities = Fcons (intern("digests"), capabilities); | 2429 | capabilities = Fcons (intern("digests"), capabilities); |