From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: Re: Service names on machines with bad service files Date: Mon, 19 Sep 2011 15:07:28 -0400 Message-ID: <87obyg9wr3.fsf@stupidchicken.com> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1316465204 4068 80.91.229.12 (19 Sep 2011 20:46:44 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 19 Sep 2011 20:46:44 +0000 (UTC) Cc: emacs-devel@gnu.org To: Lars Magne Ingebrigtsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Sep 19 22:46:40 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1R5kjf-0005yf-VC for ged-emacs-devel@m.gmane.org; Mon, 19 Sep 2011 22:46:40 +0200 Original-Received: from localhost ([::1]:58934 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R5jC0-00019j-I0 for ged-emacs-devel@m.gmane.org; Mon, 19 Sep 2011 15:07:48 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:58990) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R5jBt-00019R-FS for emacs-devel@gnu.org; Mon, 19 Sep 2011 15:07:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R5jBl-00026u-F2 for emacs-devel@gnu.org; Mon, 19 Sep 2011 15:07:41 -0400 Original-Received: from vm-emlprdomr-02.its.yale.edu ([130.132.50.143]:34315) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R5jBl-00026q-A7 for emacs-devel@gnu.org; Mon, 19 Sep 2011 15:07:33 -0400 Original-Received: from furball (dhcp-128-36-169-222.central.yale.edu [128.36.169.222]) (authenticated bits=0) by vm-emlprdomr-02.its.yale.edu (8.14.4/8.14.4) with ESMTP id p8JJ7STO024452 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Mon, 19 Sep 2011 15:07:28 -0400 In-Reply-To: (Lars Magne Ingebrigtsen's message of "Mon, 19 Sep 2011 11:40:16 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-Scanned-By: MIMEDefang 2.71 on 130.132.50.143 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 130.132.50.143 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:144106 Archived-At: Lars Magne Ingebrigtsen writes: > Lars Magne Ingebrigtsen writes: > >> 2) Somehow determine that the OS doesn't know what "imaps" is, and use >> "993" as a fallback. I have no idea whether that's easy to do. > > This would be very easy to do. It would mean making a new C-level > function that basically just calls getservbyname and returns the port > number. So nnimap would the call `open-network-stream' with > (or (service-port-number "imaps") 993). > > That sounds quite nice, doesn't it? I'd rather use just 993. Doing (or (service-port-number "imaps") 993) doesn't really make sense. OTOH, no one will ever change the service names from their standard values, so the value will always be 993 anyway.