From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: "Preserve owner and group" on MSDOS/Windows Date: Fri, 24 Jun 2005 13:45:22 +0200 Message-ID: References: Reply-To: Eli Zaretskii NNTP-Posting-Host: main.gmane.org X-Trace: sea.gmane.org 1119610854 14892 80.91.229.2 (24 Jun 2005 11:00:54 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 24 Jun 2005 11:00:54 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jun 24 13:00:53 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1DllvE-0002EA-97 for ged-emacs-devel@m.gmane.org; Fri, 24 Jun 2005 13:00:32 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Dlm2F-0007sD-1Q for ged-emacs-devel@m.gmane.org; Fri, 24 Jun 2005 07:07:47 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Dlm0R-0007Mm-0z for emacs-devel@gnu.org; Fri, 24 Jun 2005 07:05:58 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Dlm0K-0007JQ-AS for emacs-devel@gnu.org; Fri, 24 Jun 2005 07:05:51 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Dlm0I-00075p-Da for emacs-devel@gnu.org; Fri, 24 Jun 2005 07:05:46 -0400 Original-Received: from [192.114.186.66] (helo=romy.inter.net.il) by monty-python.gnu.org with esmtp (Exim 4.34) id 1Dllk7-0001S5-OG for emacs-devel@gnu.org; Fri, 24 Jun 2005 06:49:03 -0400 Original-Received: from HOME-C4E4A596F7 (IGLD-83-130-207-40.inter.net.il [83.130.207.40]) by romy.inter.net.il (MOS 3.5.8-GR) with ESMTP id BQC23192 (AUTH halo1); Fri, 24 Jun 2005 13:45:24 +0300 (IDT) Original-To: Juanma Barranquero In-reply-to: (message from Juanma Barranquero on Fri, 24 Jun 2005 11:08:20 +0200) 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:39421 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:39421 > Date: Fri, 24 Jun 2005 11:08:20 +0200 > From: Juanma Barranquero > > This change fails on Windows (no chown function): > > 2005-06-23 Richard M. Stallman > > * fileio.c (Frename_file): Preserve owner and group, if possible, > when copying. > > I've wrapped it with #ifndef DOS_NT. I don't think any other action is needed. I don't think this is the best solution. It is IMHO much better to add to w32.c a trivial `chown' that does nothing; then the ugly ifdef can go away. (The DOS port doesn't need the ifdef anyway, since the DJGPP library already has such a no-op implementation of `chown'.) I think system-dependcent ifdef's should be the last resort in such situations. I've just installed a change along these lines (and undid yours). (A more meaningful implementation of `chown' for w32, that uses GetNamedSecurityInfo and SetNamedSecurityInfo, is left as an exercise to the reader ;-)