git-for-windows / git

A fork of Git containing Windows-specific patches.
http://gitforwindows.org/
Other
8.18k stars 2.49k forks source link

warning: failed to restrict file handles (5) #5012

Open TomClabault opened 2 weeks ago

TomClabault commented 2 weeks ago

4748 is related.

Setup

$ git --version --build-options

git version 2.45.2.windows.1
cpu: x86_64
built from commit: 91d03cb2e4fbf6ad961ace739b8a646868cb154d
sizeof-long: 4
sizeof-size_t: 8
shell-path: /bin/sh
feature: fsmonitor--daemon
$ cmd.exe /c ver

Microsoft Windows [version 10.0.22631.3737]
# One of the following:
> type "C:\Program Files\Git\etc\install-options.txt"
> type "C:\Program Files (x86)\Git\etc\install-options.txt"
> type "%USERPROFILE%\AppData\Local\Programs\Git\etc\install-options.txt"
> type "$env:USERPROFILE\AppData\Local\Programs\Git\etc\install-options.txt"
$ cat /etc/install-options.txt

Editor Option: Notepad++
Custom Editor Path: 
Default Branch Option:  
Path Option: Cmd
SSH Option: OpenSSH
Tortoise Option: false
CURL Option: OpenSSL
CRLF Option: CRLFAlways
Bash Terminal Option: MinTTY
Git Pull Behavior Option: Merge
Use Credential Manager: Enabled
Performance Tweaks FSCache: Enabled
Enable Symlinks: Disabled
Enable Pseudo Console Support: Disabled
Enable FSMonitor: Disabled

Details

Git bash

git status

I cannot reproduce the issue if I git status again.

On branch FixMIS
Your branch is up to date with 'origin/FixMIS'.

Untracked files:
  (use "git add <file>..." to include in what will be committed)
    ...

nothing added to commit but untracked files present (use "git add" to track)
warning: failed to restrict file handles (5)

handle #0: 00000000000001a0 (type 2, handle info (1) 0
handle #1: 00000000000001a4 (type 3, handle info (1) 1
handle #2: 0000000000000430 (type 3, handle info (1) 1

This is a bug; please report it at
https://github.com/git-for-windows/git/issues/new

To suppress this warning, please set the environment variable

        SUPPRESS_HANDLE_INHERITANCE_WARNING=1

On branch FixMIS
Your branch is up to date with 'origin/FixMIS'.

Untracked files:
  (use "git add <file>..." to include in what will be committed)
        ...

nothing added to commit but untracked files present (use "git add" to track)

https://github.com/TomClabault/HIPRT-Path-Tracer/tree/FixMIS

On branch FixMIS.