From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.devel Subject: Re: Emacs on windows and GnuTLS Date: Sun, 03 Nov 2013 06:33:57 -0500 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <877gcpu3bu.fsf@flea.lifelogs.com> References: Reply-To: emacs-devel@gnu.org NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1383478433 17930 80.91.229.3 (3 Nov 2013 11:33:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 3 Nov 2013 11:33:53 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Nov 03 12:33:56 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VcvwI-0005Wu-Hd for ged-emacs-devel@m.gmane.org; Sun, 03 Nov 2013 12:33:54 +0100 Original-Received: from localhost ([::1]:44794 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VcvwI-0007R3-4z for ged-emacs-devel@m.gmane.org; Sun, 03 Nov 2013 06:33:54 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39800) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vcvw8-0007Qs-DT for emacs-devel@gnu.org; Sun, 03 Nov 2013 06:33:51 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vcvw1-0002C3-4V for emacs-devel@gnu.org; Sun, 03 Nov 2013 06:33:44 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]:48770) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vcvw0-0002By-Uc for emacs-devel@gnu.org; Sun, 03 Nov 2013 06:33:37 -0500 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1Vcvvw-0005K4-Ph for emacs-devel@gnu.org; Sun, 03 Nov 2013 12:33:32 +0100 Original-Received: from c-98-229-61-72.hsd1.ma.comcast.net ([98.229.61.72]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 03 Nov 2013 12:33:32 +0100 Original-Received: from tzz by c-98-229-61-72.hsd1.ma.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 03 Nov 2013 12:33:32 +0100 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 64 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: c-98-229-61-72.hsd1.ma.comcast.net X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6; d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" Mail-Copies-To: never User-Agent: Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.3.50 (gnu/linux) Cancel-Lock: sha1:tm0EZYLokmX8rFviou+d8cFP1ak= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:164896 Archived-At: On Fri, 1 Nov 2013 23:13:21 +0100 Fabrice Popineau wrote: FP> I wanted to check that GnuTLS is ok on my Emacs installation FP> and after doing: FP> (require 'gnutls) FP> (setq gnutls-log-level 2) FP> (open-gnutls-stream "tls" "tls-buffer" "imap.gmail.com" "imaps") FP> I find these annoying messages: FP> gnutls.c: [1] (Emacs) non-fatal error: Resource temporarily unavailable, FP> try again. FP> gnutls.c: [2] ASSERT: gnutls_buffers.c:1015 FP> gnutls.c: [2] ASSERT: gnutls_buffers.c:508 FP> gnutls.c: [1] (Emacs) non-fatal error: Resource temporarily unavailable, FP> try again. FP> gnutls.c: [2] ASSERT: gnutls_buffers.c:1015 FP> thousands of times. The ASERTs are coming from GnuTLS itself. You'll have to raise the `gnutls-log-level' to 1 or 0. The non-fatal retries are probably network-related. We don't have a way, IIRC, to tell the error's severity in advance so we always issue it at level 1. But I have a note in gnutls.c: GNUTLS_LOG2 (1, max_log_level, "non-fatal error:", str); /* TODO: EAGAIN AKA Qgnutls_e_again should be level 2. */ so specifically for GNUTLS_EAGAIN we can go up to level 3. Could you try that change on your own? See below for suggested patch. I will install if it works for you. FP> I'm not sure it is even harmful. FP> Any idea what could be wrong there ? Not harmful, just annoying :) Ted === modified file 'src/gnutls.c' --- src/gnutls.c 2013-10-17 06:42:21 +0000 +++ src/gnutls.c 2013-11-03 11:31:16 +0000 @@ -487,9 +487,13 @@ } else { + bool eagain = (err == GNUTLS_E_AGAIN); + int level = eagain ? 1 : 3; ret = 1; - GNUTLS_LOG2 (1, max_log_level, "non-fatal error:", str); - /* TODO: EAGAIN AKA Qgnutls_e_again should be level 2. */ + GNUTLS_LOG2 (level, + max_log_level, + eagain ? "retry:" : "non-fatal error:", + str); } if (err == GNUTLS_E_WARNING_ALERT_RECEIVED