Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pushing to UNC paths seems broken but mounted network drives works #439

Closed
ablaylock opened this issue Sep 25, 2015 · 28 comments
Closed

Pushing to UNC paths seems broken but mounted network drives works #439

ablaylock opened this issue Sep 25, 2015 · 28 comments
Assignees

Comments

@ablaylock
Copy link

I have some projects that were configured with remotes that have a UNC path i.e. //remote-serve/myProject which were set up with git 1.9.x. It seems that with 2.5.3 they no longer work when pushing or pulling a project.

When executing a push I get the following error:

$ git push
fatal: unable to get current working directory: No error
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

when the remote is configured like:

$ git remote -v
origin  //remote-serve/myProject (fetch)
origin  //remote-serve/myProject (push)

However updating the remote url to the same share which has been mapped as a network drive works //remote-serve/ -> U:/:

$ git remote -v
origin  U:/myProject (fetch)
origin  U:/myProject (push)

System configuration:
Windows 10 x64 Pro

$ git --version
git version 2.5.3.windows.1
@dscho dscho self-assigned this Sep 25, 2015
@dscho
Copy link
Member

dscho commented Sep 25, 2015

I will probably not manage to have a look at this issue before Monday. Please feel free to ping me on Tuesday if you haven't heard back from me by then.

@kevin-david
Copy link

git clone has a similar (maybe the same) problem. Let me know if you think I should file a separate ticket.

Repro:

PS C:\VSO> New-PSDrive -Name "Z" -PSProvider FileSystem -Root "\\kedavid-dev2\d$\VSO" -Persist

Name           Used (GB)     Free (GB) Provider      Root
----           ---------     --------- --------      ----
Z                  42.38        190.49 FileSystem    \\kedavid-dev2\d$\VSO


PS C:\VSO> git clone "\\kedavid-dev2\d$\VSO\src"
Cloning into 'src'...
fatal: '\kedavid-dev2\d$\VSO\src' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
PS C:\VSO> git clone Z:\src
Cloning into 'src'...
[worked]

I tried some other combinations too:

PS C:\VSO> git clone "\\\kedavid-dev2\d$\VSO\src" src2
fatal: repository '\\\kedavid-dev2\d$\VSO\src' does not exist
PS C:\VSO> git clone "\\\\kedavid-dev2\d$\VSO\src" src2
fatal: repository '\\\\kedavid-dev2\d$\VSO\src' does not exist
PS C:\VSO> git clone '\\kedavid-dev2\d$\VSO\src' src2
Cloning into 'src2'...
fatal: '\kedavid-dev2\d$\VSO\src' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

@Radrik5
Copy link

Radrik5 commented Oct 14, 2015

I recently executed git fetch with an UNC path on Windows 7 64bit with Git 2.6.1. It worked well.
@kevin-david what versions of Windows and Git do you use?

@kevin-david
Copy link

PS C:\VSO\src> git --version
git version 2.6.1.windows.1

Edit: Forgot to mention, this is on Windows 10.

Fetch doesn't seem to be working for me either, despite the URL being set correctly:

PS C:\VSO\src> git remote set-url origin "\\kedavid-dev2\d$\VSO\src"
PS C:\VSO\src> git fetch
fatal: '\kedavid-dev2\d$\VSO\src' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
PS C:\VSO\src> git remote -v
origin  \\kedavid-dev2\d$\VSO\src (fetch)
origin  \\kedavid-dev2\d$\VSO\src (push)

@Radrik5
Copy link

Radrik5 commented Oct 14, 2015

On Windows 7 git clone also doesn't work with UNC paths, but git fetch does:

Test $ git clone '\\\\localhost\Test\test-repo' dst
fatal: repository '\\\\localhost\Test\test-repo' does not exist

Test $ git init dst
Initialized empty Git repository in D:/Test/dst/.git/

Test $ cd dst/

dst $ git fetch '\\\\localhost\Test\test-repo'
remote: Counting objects: 3, done.
remote: Total 3 (delta 0), reused 0 (delta 0)
Unpacking objects: 100% (3/3), done.
From \\\\localhost\Test\test-repo
 * branch            HEAD       -> FETCH_HEAD

Same on Windows 10. Very strange behavior, but reproduible!

@Radrik5
Copy link

Radrik5 commented Oct 14, 2015

git push also works:

$ git push '\\\\localhost\Test\test-repo' master
Counting objects: 3, done.
Writing objects: 100% (3/3), 239 bytes | 0 bytes/s, done.
Total 3 (delta 0), reused 0 (delta 0)
To \\\\localhost\Test\test-repo
   520d83c..2ef26e0  master -> master

$ git push '//localhost/Test/test-repo' master
Everything up-to-date

So, probaly the issue with git clone is not related to the original one.

@ablaylock
Copy link
Author

Testing Radrik5's comment about first init-ing the repo and then fetching doesn't work for me:

$ git init motion
Initialized empty Git repository in C:/projects/usb-printer/motion/.git/

$ cd motion
$ git fetch '\\\\uncPath\Code\motion'
fatal: unable to get current working directory: No such file or directory
fatal: The remote end hung up upon initial contact

$ git --version
git version 2.6.2.windows.1

@Radrik5
Copy link

Radrik5 commented Oct 28, 2015

@ablaylock could you try repo shared on your local PC: \\localhost\...?

@ablaylock
Copy link
Author

@Radrik5 A locally hosted repo works. Tested with the following steps (some output removed):

$ git init --bare testrepo
$ mkdir test
$ cd test
$ touch "this is a test.txt"
$ git init
$ git add .
$ git commit -am "Test commit"
$ git remote add origin '\\localhost\path\to\testrepo'
$ git push --set-upstream origin master
$ cd ..
$ git clone  '\\localhost\path\to\testrepo' test2
Cloning into 'test2'...
done.
$ cd ..
$ git clone '\\PC-HOSTNAME\path\to\testrepo' test3
Cloning into 'test3'...
done.

This however doesn't work for non-localhost repositories (i.e. those hosted on another computer).

@Radrik5
Copy link

Radrik5 commented Oct 28, 2015

@ablaylock could you also try repo shared on another remote?
Probably there is a difference in configuration of your local share and remote share that doesn't work for you. The sooner we find that difference, the sooner we can reproduce the problem and fix it.

@ablaylock
Copy link
Author

@Radrik5 Cloning from a different computer with a different share works.
Configuration details:

PC1 -> Windows 10 Pro x64
PC2 -> Windows 7 Pro x64
Server1 -> Windows Server 2008 R2 w/SP1

Server -> Client
PC1 -> PC1 Cloning works with localhost and hostname.
PC1 -> PC2 Cloning works with hostname
Server1 -> PC1 Cloning does not work with hostname (unc path, error below). Does work with mapped network drive.

Cloning into 'reponame'...
fatal: unable to get current working directory: No such file or directory
fatal: The remote end hung up upon initial contact

Server1 -> PC2 Cloning does not work. Error:

Cloning into 'reponame'...
fatal: unable to get current working directory: No such file or directory
fatal: The remote end hung up upon initial contact

@Radrik5
Copy link

Radrik5 commented Oct 29, 2015

@ablaylock this looks like a configuration issue on Server1 (permissions of something else). Could you install Git 1.9.5 and confirm that it still works with Server1?

@ablaylock
Copy link
Author

@Radrik5 Testing with Git 1.9.5 does work with the following commands on Server1. I downloaded this version:
https://github.com/msysgit/msysgit/releases/download/Git-1.9.5-preview20150319/Git-1.9.5-preview20150319.exe

$ git version
git version 1.9.5.msysgit.1

$ git clone //Server1/workspace/motion
Cloning into 'motion'...
done.

Trying the exact same commands in git 2.6.2:

$ git version
git version 2.6.2.windows.1

$ git clone //Server1/workspace/motion
Cloning into 'motion'...
fatal: unable to get current working directory: No such file or directory
fatal: The remote end hung up upon initial contact

@Radrik5
Copy link

Radrik5 commented Nov 2, 2015

@ablaylock unfortunately I don't have more ideas on how to find the cause of the problem. Please try to create a reproducible example (why repo shared on Server1 doesn't work?) or try to debug the git process. Some time ago I used Eclipse and gdb but maybe there are better tools today. @dscho may help with this.

@ablaylock
Copy link
Author

Is there a discussion of how to debug git. I looked at the wiki for this project and arrived at this page for "Building and Debugging"
https://github.com/git-for-windows/git/wiki/Building-Git
but found no debugging information. If someone can help me get a debugger attached I am willing to do the debugging myself.

@dscho
Copy link
Member

dscho commented Nov 9, 2015

@ablaylock I just described the steps here.

@dscho
Copy link
Member

dscho commented Nov 30, 2015

I was able to perform a quick test, and can verify that git push \\server\share HEAD does not work.

However, using //server/share or \\\\server\share do work...

@mkaut
Copy link

mkaut commented Dec 8, 2015

I also have a problem with cloning:
git clone file:////server/share/repo works for me (the owner of the share), but not for my colleague with whom I have shared the folder. He gets:

Cloning into 'test'...
fatal: unable to get current working directory: No such file or directory
fatal: The remote end hung up upon initial contact

He has read/write permission to the folder.
He can clone using cygwin-version of git.
Once this is done, he can push to the repo using Windows git.

@dscho
Copy link
Member

dscho commented Dec 12, 2015

@mkaut please do not hide bug reports in unrelated tickets ("unable to get current working directory" is clearly unrelated to UNC paths, and you will find that searching for that phrase turns up other tickets that would be more appropriate).

sowmyasudhakar pushed a commit to sowmyasudhakar/angular-phonecat that referenced this issue Oct 14, 2016
@dscho
Copy link
Member

dscho commented Feb 21, 2017

There has been some substantial work on UNC paths recently. Sadly, I am really scarce on time; would you mind testing with v2.11.1?

@dscho dscho closed this as completed Apr 4, 2017
@kasajian
Copy link

I have a scenario where I can reproduce this problem. I found that I don't get the problem with Git version 2.5.2, but I can reproduce it with 2.5.3.

@dscho
Copy link
Member

dscho commented Jun 19, 2017

I found that I don't get the problem with Git version 2.5.2, but I can reproduce it with 2.5.3.

Wow, speaking of going back some ways ;-)

Having said that, have you read this comment?

I have a scenario where I can reproduce this problem.

Maybe you want to describe the scenario, as well as the exact steps, and in particular the exact output.

If you clone from, say, //myserver/some/folder/repository.git, I would expect it to work. If you clone from \\myserver\some\folder\repository.git, I know it will fail because it strips the first backslash. I am working on that, though.

In the meantime, please increase the verbosity, it is very frustrating for me otherwise (and you want to keep me happy, don't you, as that's all you have to offer me, eh? 😄).

dscho added a commit that referenced this issue Jun 20, 2017
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
git-for-windows-ci pushed a commit that referenced this issue Jun 20, 2017
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit that referenced this issue Aug 23, 2018
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit that referenced this issue Aug 23, 2018
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
jamill pushed a commit to jamill/git that referenced this issue Aug 28, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
jamill pushed a commit to jamill/git that referenced this issue Sep 5, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
git-for-windows-ci pushed a commit that referenced this issue Sep 10, 2018
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
jamill pushed a commit to jamill/git that referenced this issue Sep 11, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
git-for-windows-ci pushed a commit that referenced this issue Sep 24, 2018
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit that referenced this issue Oct 10, 2018
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Oct 11, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Nov 19, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Nov 20, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit that referenced this issue Nov 21, 2018
This topic branch addresses a problem identified in
#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Nov 23, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Nov 30, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Dec 1, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Dec 9, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Dec 15, 2018
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
dscho added a commit to dscho/git that referenced this issue Feb 7, 2019
This topic branch addresses a problem identified in
git-for-windows#439: while
cloning/fetching/pushing from "POSIX-ified UNC paths" (i.e. UNC paths
whose backslashes have been converted to forward slashes) works for some
time now, true UNC paths (with backslashes left intact) were handled
incorrectly. Example:

	git clone //myserver/folder/repo.git

works, but

	git clone \\myserver\folder\repo.git

(in CMD; in Git Bash, the backslashes would need to be doubled) used to
fail. The reason was an unexpected difference in command-line handling
between Win32 executables and MSYS2 ones (such as the shell that is used
by git-clone.exe to spawn git-upload-pack.exe).

This topic branch features a workaround *just* for the case where Git
passes stuff through sh.exe (which covers quite a few use cases,
though).

Signed-off-by: Johannes Schindelin <[email protected]>
jeffhostetler pushed a commit to jeffhostetler/git that referenced this issue Oct 13, 2021
…ree bug in cache_tree_verify()

This is a copy of [the v2 patch sent by Philip Wood](https://lore.kernel.org/git/[email protected]/T/#u). This fixes a possible segfault when a `git rebase --apply` creates a full cache tree in a sparse index.

There is a slight change from Philip's patch that makes the test more robust to verbose output.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants