From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Sven Joachim Newsgroups: gmane.emacs.bugs Subject: bug#1224: [PATCH] user/group name completion Date: Sun, 12 Jul 2009 22:29:38 +0200 Message-ID: <87ocrp63wt.fsf@turtle.gmx.de> References: <87eisln22i.fsf@stupidchicken.com> <837hydsmlp.fsf@gnu.org> Reply-To: Sven Joachim , 1224@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1247431069 26035 80.91.229.12 (12 Jul 2009 20:37:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 12 Jul 2009 20:37:49 +0000 (UTC) Cc: Chong Yidong , 1224@emacsbugs.donarmstrong.com, dmantipov@yandex.ru To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jul 12 22:37:42 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MQ5np-00088u-TC for geb-bug-gnu-emacs@m.gmane.org; Sun, 12 Jul 2009 22:37:42 +0200 Original-Received: from localhost ([127.0.0.1]:50814 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MQ5no-0003UF-RT for geb-bug-gnu-emacs@m.gmane.org; Sun, 12 Jul 2009 16:37:40 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MQ5nj-0003Tu-Lf for bug-gnu-emacs@gnu.org; Sun, 12 Jul 2009 16:37:35 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MQ5nf-0003Tc-Ah for bug-gnu-emacs@gnu.org; Sun, 12 Jul 2009 16:37:35 -0400 Original-Received: from [199.232.76.173] (port=39885 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MQ5ne-0003TS-UV for bug-gnu-emacs@gnu.org; Sun, 12 Jul 2009 16:37:30 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:35398) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MQ5ne-0001WH-7u for bug-gnu-emacs@gnu.org; Sun, 12 Jul 2009 16:37:30 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id n6CKbRSD031523; Sun, 12 Jul 2009 13:37:28 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id n6CKZ5VF030895; Sun, 12 Jul 2009 13:35:05 -0700 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Sven Joachim Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Sun, 12 Jul 2009 20:35:05 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 1224 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: patch Original-Received: via spool by 1224-submit@emacsbugs.donarmstrong.com id=B1224.124743059229942 (code B ref 1224); Sun, 12 Jul 2009 20:35:05 +0000 Original-Received: (at 1224) by emacsbugs.donarmstrong.com; 12 Jul 2009 20:29:52 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with SMTP id n6CKTkvF029936 for <1224@emacsbugs.donarmstrong.com>; Sun, 12 Jul 2009 13:29:48 -0700 Original-Received: (qmail invoked by alias); 12 Jul 2009 20:29:40 -0000 Original-Received: from p548644DC.dip.t-dialin.net (EHLO turtle.gmx.de) [84.134.68.220] by mail.gmx.net (mp059) with SMTP; 12 Jul 2009 22:29:40 +0200 X-Authenticated: #28250155 X-Provags-ID: V01U2FsdGVkX19ltBc4IwpliAqRrsrSIRmMcfiWnpP637X0vBW/Z8 DG8Jrd5p9eWC0n Original-Received: by turtle.gmx.de (Postfix, from userid 1000) id 55817354A2; Sun, 12 Jul 2009 22:29:39 +0200 (CEST) In-Reply-To: <837hydsmlp.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 12 Jul 2009 22:54:58 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.96 (gnu/linux) X-Y-GMX-Trusted: 0 X-FuHaFi: 0.62 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Sun, 12 Jul 2009 16:37:35 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:29370 Archived-At: On 2009-07-12 21:54 +0200, Eli Zaretskii wrote: >> From: Chong Yidong >> Date: Sun, 12 Jul 2009 15:17:25 -0400 >> Cc: 1224@emacsbugs.donarmstrong.com >> >> The other part of your patch, adding functions to the C code that call >> getpwent and getgrent, may be useful. But I don't see the advantage >> over parsing /etc/passwd or /etc/group manually (or calling a shell >> command that does it). > > The advantage is that getpwent and getgrent are more portable, of > course. > > Only Posix systems can be trusted to actually have /etc/passwd and > /etc/groups. And even on those systems these files do not necessarily hold the user database, there is NIS, LDAP,... > On systems where these files are absent, we can still > have the C APIs (or craft our owns inside Emacs, as w32.c does). Please use them everywhere, manually parsing /etc/passwd and /etc/group is broken behavior. Sven