Hmm, this explanation makes me wonder: Could this be related to the
deadlock we're experiencing with git-push over the git-protocol on
Windows when side-band-64k is enabled?
No, It doesn't seem like that's it. The socket buffers appears to be
8k by default on Windows, which should be plenty, right?
---8<---
diff --git a/compat/mingw.c b/compat/mingw.c
index d527562..985c271 100644
--- a/compat/mingw.c
+++ b/compat/mingw.c
@@ -1404,7 +1404,7 @@ int mingw_getnameinfo(const struct sockaddr *sa,
socklen_t salen,
int mingw_socket(int domain, int type, int protocol)
{
- int sockfd;
+ int sockfd, val, len;
SOCKET s;
ensure_socket_initialization();
@@ -1428,6 +1428,12 @@ int mingw_socket(int domain, int type, int protocol)
return error("unable to make a socket file descriptor: %s",
strerror(errno));
}
+
+ len = sizeof(val);
+ if (!getsockopt(s, SOL_SOCKET, SO_RCVBUF, (char *)&val, &len))
+ fprintf(stderr, "SO_RCVBUF: %d\n", val);
+ len = sizeof(val);
+ if (!getsockopt(s, SOL_SOCKET, SO_SNDBUF, (char *)&val, &len))
+ fprintf(stderr, "SO_SNDBUF: %d\n", val);
return sockfd;
}
---8<---
$ git push git://localhost
SO_RCVBUF: 8192
SO_SNDBUF: 8192
...
I think its unrelated. It might also be a deadlock, but the push
protocol is quite a bit different. As far as I remember, there is no
risk of deadlock in the push protocol.
--
Shawn.