git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Git changes permissions on directories when deleting files.

From
Chad Joan <chadjoan@gmail.com>
Date
Mar 1, 2011, 20:30 UTC
Message-ID
<AANLkTint3PARNNN4cpic8XG6HsM3AAGuX5a+oeXfFNx=@mail.gmail.com>
In-Reply-To
<20110301200805.GA18587@sigill.intra.peff.net>
On Tue, Mar 1, 2011 at 3:08 PM, Jeff King <peff@peff.net> wrote:
Show 28 quoted lines
> On Tue, Mar 01, 2011 at 02:57:19PM -0500, Chad Joan wrote:
>
>> > Exactly. Rather than spend time figuring out if the directory is
>> > removable (which would not be atomic, anyway), we just rmdir and ignore
>> > the error condition.
>> >
>> > I would argue that your filesystem is broken. Even if we implemented a
>> > workaround to opendir() and check for files, it would still have a race
>> > condition that could cause this situation to occur.
>>
>> Ouch.
>>
>> Would it work to do something like alias rmdir to a script or program
>> that would call /bin/rmdir and then fix up the permissions?
>
> Well, we're using the rmdir system call, so you would need a patch to
> git either way. If that was something we wanted to support (with a
> config option, of course), we could do the permissions check-and-restore
> ourselves.
>
> But it just seems horribly broken to me. This is CIFS to an OpenVMS
> machine you said? Do the broken permissions appear to other clients or
> across a remount (i.e., is it broken state in your CIFS client, or has
> the server actually munged permissions)? If so, have you tried reporting
> the issue to whoever writes CIFS server on OpenVMS (is it just samba)?
>
> -Peff
>
Yep, CIFS to OpenVMS.

I don't know about other clients because there are none (yet). The permission change does survive remounting.

I haven't reported it.  I didn't know it existed until now ;)

I'll do that, but it will probably take a long long time for me to see the patch. I'm hoping there's some cheap hack I can use to work around it in the meantime.

- Chad
Previous: Jeff KingNext: Computer Druid
Message 11 of 19 in “Git changes permissions on directories when deleting files.”
  1. Chad JoanMar 1, 2011
  2. Chad JoanMar 1, 2011
  3. Computer DruidMar 1, 2011
  4. Chad JoanMar 1, 2011
  5. Chad JoanMar 1, 2011
  6. Computer DruidMar 1, 2011
  7. Chad JoanMar 1, 2011
  8. Jeff KingMar 1, 2011
  9. Chad JoanMar 1, 2011
  10. Jeff KingMar 1, 2011
  11. Chad JoanMar 1, 2011
  12. Computer DruidMar 1, 2011
  13. Jeff KingMar 1, 2011
  14. Matthieu MoyMar 1, 2011
  15. Chad JoanMar 1, 2011
  16. Jeff KingMar 1, 2011
  17. Chad JoanMar 3, 2011
  18. Jeff KingMar 3, 2011
  19. Chad JoanMar 11, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.