Opened 6 years ago

Closed 6 years ago

#183 closed defect (fixed)

git config --remove-section XYZ fails

Reported by: dmik Owned by:
Priority: major Milestone:
Component: git Version:
Severity: medium Keywords:
Cc:

Description

Steps:

  1. git init
  2. git config foo bar
  3. git config --remove-section foo

The last one fails with:

error: chmod on D:/Coding/qt5/t/.git/config.lock failed: Permission denied

Discovered within https://github.com/bitwiseworks/qt5-os2/issues/2.

Change History (1)

comment:1 by dmik, 6 years ago

Resolution: fixed
Status: newclosed

Note that this is a global kLIBC problem, see http://trac.netlabs.org/libc/ticket/230#comment:6. And the proper way here is to fix the Git source where using chmod is not very efficient in the first place since there is fchmod and we know the file descriptor (so that there will be no need to look up for an inode for a given file as it will be available through the associated open file structure corresponding the given fd).

And the fun thing is that I already did something similar in this part of the code, see #37 and r1866.

Anyway, fixed this in r2283.

Note: See TracTickets for help on using tickets.