From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: claudio.bley@gmail.com (Claudio Bley) Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] GnuTLS support on Woe32 Date: Mon, 14 Mar 2011 08:43:50 +0100 Message-ID: <84zkoy6tah.wl%claudio.bley@gmail.com> References: <87ipvwl1nx.wl%claudio.bley@gmail.com> <83oc5ogp89.fsf@gnu.org> <87ipvuwslp.wl%claudio.bley@gmail.com> <87hbbc0zi6.wl%claudio.bley@gmail.com> <83oc5gsdwc.fsf@gnu.org> <87ei6bunxz.wl%claudio.bley@gmail.com> <83tyf6rhgn.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Trace: dough.gmane.org 1300088688 21569 80.91.229.12 (14 Mar 2011 07:44:48 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 14 Mar 2011 07:44:48 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Mar 14 08:44:44 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Pz2SK-00036J-6X for ged-emacs-devel@m.gmane.org; Mon, 14 Mar 2011 08:44:44 +0100 Original-Received: from localhost ([127.0.0.1]:36671 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pz2SI-0007kI-PZ for ged-emacs-devel@m.gmane.org; Mon, 14 Mar 2011 03:44:42 -0400 Original-Received: from [140.186.70.92] (port=50993 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pz2Rm-0007jY-Tf for emacs-devel@gnu.org; Mon, 14 Mar 2011 03:44:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pz2Ri-0001wI-Gj for emacs-devel@gnu.org; Mon, 14 Mar 2011 03:44:10 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:33029) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pz2Ri-0001vl-48 for emacs-devel@gnu.org; Mon, 14 Mar 2011 03:44:06 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Pz2Rg-0002xY-Ko for emacs-devel@gnu.org; Mon, 14 Mar 2011 08:44:04 +0100 Original-Received: from 178-24-235-97-dynip.superkabel.de ([178.24.235.97]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 14 Mar 2011 08:44:04 +0100 Original-Received: from claudio.bley by 178-24-235-97-dynip.superkabel.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 14 Mar 2011 08:44:04 +0100 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 55 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 178-24-235-97-dynip.superkabel.de In-Reply-To: <83tyf6rhgn.fsf@gnu.org> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/24.0.50 (i386-mingw-nt5.1.2600) MULE/6.0 (HANACHIRUSATO) Mail-Copies-To: never X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 80.91.229.12 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:137210 Archived-At: At Sun, 13 Mar 2011 20:41:28 +0200, Eli Zaretskii wrote: > > > From: claudio.bley@gmail.com (Claudio Bley) > > Date: Sun, 13 Mar 2011 14:53:12 +0100 > > > > > If all you need is to produce EAGAIN when you have EWOULDBLOCK (the > > > other mapping is already in set_errno), it hardly justifies a > > > function. > > > > That's true, WSAEINTR already gets mapped. Must have missed that. > > So are we in agreement that a separate new function is not required? Yes, absolutely. > > > > > > > +static ssize_t > > > > > > > +emacs_gnutls_pull(gnutls_transport_ptr_t p, void* buf, size_t sz) > > > > > > > > > > > > Can we move the Windows-specific functions to w32.c, and only call > > > > > > them from gnutls.c? I think we want to keep the Windows-related code > > > > > > outside w32*.c to the bare minimum. > > > > > > > > > > OK. > > > > > > > > Maybe the GnuTLS specific stuff should also be kept to the bare > > > > minimum outside of gnutls.c? > > > > > > What stuff did you have in mind? > > > > All the GnuTLS related functions (even if Windows specific). > > That's not what we do in Emacs. OS-specific #define's are best kept > to a minimum, the sole exception being sysdep.c. Otherwise, we try to > keep code of non-Posix and niche platforms on their specific sources > files. It's just that these functions are not really OS-specific in any way. I'd rather say they are GnuTLS specific. > > > > Considering that these functions would have to be non-static in this > > > > case to be accessible by gnutls.c. > > > > > > Sure, but I see no problem with that. > > > > I'm usually a bit reluctant to create public functions in a module > > which only serve a special purpose in one single other module. > > Why? Emacs is a program, not a general-purpose library. Invading > some unknown namespace should not be an issue. Never mind. I'm OK with moving them to w32.c. Consider this done. - Claudio