<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/compat, branch v2.37.4</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.37.4</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.37.4'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2022-09-13T19:21:08Z</updated>
<entry>
<title>Merge branch 'jk/pipe-command-nonblock' into maint</title>
<updated>2022-09-13T19:21:08Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2022-09-13T19:21:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=aa31cb89743a9ba4efd43f5160bfea0a4cbe5858'/>
<id>urn:sha1:aa31cb89743a9ba4efd43f5160bfea0a4cbe5858</id>
<content type='text'>
Fix deadlocks between main Git process and subprocess spawned via
the pipe_command() API, that can kill "git add -p" that was
reimplemented in C recently.

* jk/pipe-command-nonblock:
  pipe_command(): mark stdin descriptor as non-blocking
  pipe_command(): handle ENOSPC when writing to a pipe
  pipe_command(): avoid xwrite() for writing to pipe
  git-compat-util: make MAX_IO_SIZE define globally available
  nonblock: support Windows
  compat: add function to enable nonblocking pipes
</content>
</entry>
<entry>
<title>Merge branch 'js/safe-directory-plus' into maint</title>
<updated>2022-08-26T18:13:12Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2022-08-26T18:13:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=10f9eab3473c568264e0f2437d7031c5bb6bb443'/>
<id>urn:sha1:10f9eab3473c568264e0f2437d7031c5bb6bb443</id>
<content type='text'>
Platform-specific code that determines if a directory is OK to use
as a repository has been taught to report more details, especially
on Windows.
source: &lt;pull.1286.v2.git.1659965270.gitgitgadget@gmail.com&gt;

* js/safe-directory-plus:
  mingw: handle a file owned by the Administrators group correctly
  mingw: be more informative when ownership check fails on FAT32
  mingw: provide details about unsafe directories' ownership
  setup: prepare for more detailed "dubious ownership" messages
  setup: fix some formatting
</content>
</entry>
<entry>
<title>Merge branch 'js/lstat-mingw-enotdir-fix' into maint</title>
<updated>2022-08-26T18:13:10Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2022-08-26T18:13:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=69c99b85e7f25b6a04bd28a2198538119bf1e1f0'/>
<id>urn:sha1:69c99b85e7f25b6a04bd28a2198538119bf1e1f0</id>
<content type='text'>
Fix to lstat() emulation on Windows.
source: &lt;pull.1291.v3.git.1659089152877.gitgitgadget@gmail.com&gt;

* js/lstat-mingw-enotdir-fix:
  lstat(mingw): correctly detect ENOTDIR scenarios
</content>
</entry>
<entry>
<title>nonblock: support Windows</title>
<updated>2022-08-17T16:21:40Z</updated>
<author>
<name>René Scharfe</name>
<email>l.s.r@web.de</email>
</author>
<published>2022-08-17T06:05:25Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=24b56ae4aecc937a246efb94d283f54a7f59c7f1'/>
<id>urn:sha1:24b56ae4aecc937a246efb94d283f54a7f59c7f1</id>
<content type='text'>
Implement enable_pipe_nonblock() using the Windows API. This works only
for pipes, but that is sufficient for this limited interface. Despite
the API calls used, it handles both "named" and anonymous pipes from our
pipe() emulation.

Signed-off-by: René Scharfe &lt;l.s.r@web.de&gt;
Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>compat: add function to enable nonblocking pipes</title>
<updated>2022-08-17T16:21:40Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2022-08-17T06:04:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=10f743389ca9a92720fb9c3d15f647888d82c297'/>
<id>urn:sha1:10f743389ca9a92720fb9c3d15f647888d82c297</id>
<content type='text'>
We'd like to be able to make some of our pipes nonblocking so that
poll() can be used effectively, but O_NONBLOCK isn't portable. Let's
introduce a compat wrapper so this can be abstracted for each platform.

The interface is as narrow as possible to let platforms do what's
natural there (rather than having to implement fcntl() and a fake
O_NONBLOCK for example, or having to handle other types of descriptors).

The next commit will add Windows support, at which point we should be
covering all platforms in practice. But if we do find some other
platform without O_NONBLOCK, we'll return ENOSYS. Arguably we could just
trigger a build-time #error in this case, which would catch the problem
earlier. But since we're not planning to use this compat wrapper in many
code paths, a seldom-seen runtime error may be friendlier for such a
platform than blocking compilation completely. Our test suite would
still notice it.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>mingw: handle a file owned by the Administrators group correctly</title>
<updated>2022-08-08T16:33:13Z</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2022-08-08T13:27:50Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=3f7207e2ea967fd2b46d9e0ae85246e93b38ed58'/>
<id>urn:sha1:3f7207e2ea967fd2b46d9e0ae85246e93b38ed58</id>
<content type='text'>
When an Administrator creates a file or directory, the created
file/directory is owned not by the Administrator SID, but by the
_Administrators Group_ SID. The reason is that users with administrator
privileges usually run in unprivileged ("non-elevated") mode, and their
user SID does not change when running in elevated mode.

This is is relevant e.g. when running a GitHub workflow on a build
agent, which runs in elevated mode: cloning a Git repository in a script
step will cause the worktree to be owned by the Administrators Group
SID, for example.

Let's handle this case as following: if the current user is an
administrator, Git should consider a worktree owned by the
Administrators Group as if it were owned by said user.

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>mingw: be more informative when ownership check fails on FAT32</title>
<updated>2022-08-08T16:31:41Z</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2022-08-08T13:27:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7c83470e64eadab74689427fcd95e72f0a772ab5'/>
<id>urn:sha1:7c83470e64eadab74689427fcd95e72f0a772ab5</id>
<content type='text'>
The FAT file system has no concept of ACLs. Therefore, it cannot store
any ownership information anyway, and the `GetNamedSecurityInfoW()` call
pretends that everything is owned "by the world".

Let's special-case that scenario and tell the user what's going on.

This addresses https://github.com/git-for-windows/git/issues/3886

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>mingw: provide details about unsafe directories' ownership</title>
<updated>2022-08-08T16:29:29Z</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2022-08-08T13:27:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e883e04b68ba7393029bcbeaa2aacb3dff5d3fbd'/>
<id>urn:sha1:e883e04b68ba7393029bcbeaa2aacb3dff5d3fbd</id>
<content type='text'>
When Git refuses to use an existing repository because it is owned by
someone else than the current user, it can be a bit tricky on Windows to
figure out what is going on.

Let's help with that by providing more detailed information.

Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>setup: prepare for more detailed "dubious ownership" messages</title>
<updated>2022-08-08T16:25:40Z</updated>
<author>
<name>Johannes Schindelin</name>
<email>johannes.schindelin@gmx.de</email>
</author>
<published>2022-08-08T13:27:47Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=17d3883fe9c88b823002ad9fafb42313ddc3d3d5'/>
<id>urn:sha1:17d3883fe9c88b823002ad9fafb42313ddc3d3d5</id>
<content type='text'>
When verifying the ownership of the Git directory, we sometimes would
like to say a bit more about it, e.g. when using a platform-dependent
code path (think: Windows has the permission model that is so different
from Unix'), but only when it is a appropriate to actually say
something.

To allow for that, collect that information and hand it back to the
caller (whose responsibility it is to show it or not).

Note: We do not actually fill in any platform-dependent information yet,
this commit just adds the infrastructure to be able to do so.

Based-on-an-idea-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Signed-off-by: Johannes Schindelin &lt;johannes.schindelin@gmx.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'ds/win-syslog-compiler-fix' into maint</title>
<updated>2022-08-05T22:51:37Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2022-08-05T22:51:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=cba4c4a244b8293af695e3fb7965fd73c160447a'/>
<id>urn:sha1:cba4c4a244b8293af695e3fb7965fd73c160447a</id>
<content type='text'>
Workaround for a false positive compiler warning.
source: &lt;pull.1294.git.1658256354725.gitgitgadget@gmail.com&gt;

* ds/win-syslog-compiler-fix:
  compat/win32: correct for incorrect compiler warning
</content>
</entry>
</feed>
