From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13031 invoked by alias); 14 Oct 2011 10:43:00 -0000 Received: (qmail 13021 invoked by uid 22791); 14 Oct 2011 10:43:00 -0000 X-SWARE-Spam-Status: No, hits=-1.2 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_NEUTRAL,TW_MV X-Spam-Check-By: sourceware.org Received: from granite1.mail.cornell.edu (HELO authusersmtp.mail.cornell.edu) (128.253.83.141) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 14 Oct 2011 10:42:46 +0000 Received: from [192.168.1.4] (cpe-67-249-194-47.twcny.res.rr.com [67.249.194.47]) (authenticated bits=0) by authusersmtp.mail.cornell.edu (8.14.4/8.12.10) with ESMTP id p9EAgilT005842 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT) for ; Fri, 14 Oct 2011 06:42:45 -0400 (EDT) Message-ID: <4E981221.5080102@cornell.edu> Date: Fri, 14 Oct 2011 10:43:00 -0000 From: Ken Brown User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:7.0.1) Gecko/20110929 Thunderbird/7.0.1 MIME-Version: 1.0 To: cygwin@cygwin.com Subject: Re: 1.7.9-1 Patch command mangles permissions on windows 7 References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com X-SW-Source: 2011-10/txt/msg00249.txt.bz2 On 10/13/2011 7:15 PM, Roger Pack wrote: > Forgive me if this is a commonly reported bug, but I wasn't sure if > other discussions on permissions issues were the same as this issue... > > $ c:\installs\cygwin\bin\patch.exe -p0< multithread_utilities_trunk.diff > (Stripping trailing CRs from patch.) > patching file xxx/yyy/zzz/Test.java > ... > > now attempt to use the files I just patched: > > $ mvn clean install > ... > [ERROR] error: error reading xxx\yyy\zzz\Test.java; > xxx\yyy\zzz.java (Access is denied) > > I was able to reproduce this on another computer, as well. > Windows 7, 64 bit, blah blah blah. > > When I right click on the files and go to properties -> security, > somehow all users except administrators have no rights to the modified > files. This could be related to the problem discussed starting at http://cygwin.com/ml/cygwin/2009-11/msg00922.html The issue there was ACLs on the temporary directory used by patch. The resolution of that was to set TMP and TEMP to "/tmp" in Cygwin's default startup files (see /etc/defaults/profile). But you appear to be running patch outside of a Cygwin shell, so you're not benefiting from that fix. (I'm basing this guess on the fact that you start patch by giving its Windows path.) Ken -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple