diff --git a/connect.c b/connect.c
index 715cdc022340f8792c4bad45ba6a84c27bbfaa7f..ae49c5a367f9f5b77b07228fcd241fd73a5711b0 100644 (file)
--- a/connect.c
+++ b/connect.c
return PROTO_SSH;
if (!strcmp(name, "ssh+git"))
return PROTO_SSH;
+ if (!strcmp(name, "file"))
+ return PROTO_LOCAL;
die("I don't handle protocol '%s'", name);
}
end = host;
path = strchr(end, c);
- if (c == ':') {
- if (path) {
+ if (path) {
+ if (c == ':') {
protocol = PROTO_SSH;
*path++ = '\0';
- } else
- path = host;
- }
+ }
+ } else
+ path = end;
if (!path || !*path)
die("No path specified. See 'man git-pull' for valid url syntax");