emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs on windows and GnuTLS


From: Ted Zlatanov
Subject: Re: Emacs on windows and GnuTLS
Date: Mon, 04 Nov 2013 11:20:34 -0500
User-agent: Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.3.50 (gnu/linux)

Thanks for the review, Fabrice.

Anticipating the need for more of these special cases, here's a
switch-based approach that avoids special variables and makes the level
explicit in each case.  It's easier to read, too.  Let me know if this
works for you and I will install it.

Ted

=== modified file 'src/gnutls.c'
--- src/gnutls.c        2013-11-04 06:09:03 +0000
+++ src/gnutls.c        2013-11-04 16:16:31 +0000
@@ -488,8 +488,20 @@
   else
     {
       ret = 1;
-      GNUTLS_LOG2 (1, max_log_level, "non-fatal error:", str);
-      /* TODO: EAGAIN AKA Qgnutls_e_again should be level 2.  */
+
+      switch (err)
+        {
+        case GNUTLS_E_AGAIN:
+          GNUTLS_LOG2 (3,
+                       max_log_level,
+                       "retry:",
+                       str);
+        default:
+          GNUTLS_LOG2 (1,
+                       max_log_level,
+                       "non-fatal error:",
+                       str);
+        }
     }
 
   if (err == GNUTLS_E_WARNING_ALERT_RECEIVED


reply via email to

[Prev in Thread] Current Thread [Next in Thread]