Code

transport_get(): drop unnecessary check for !remote
authorJunio C Hamano <gitster@pobox.com>
Wed, 27 Jan 2010 20:22:37 +0000 (12:22 -0800)
committerJunio C Hamano <gitster@pobox.com>
Wed, 27 Jan 2010 20:22:37 +0000 (12:22 -0800)
At the beginning of the function we make sure remote is not NULL, and
the remainder of the funciton already depends on it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
transport.c

index 87581b85a160cb57b27e422c01a6eb76e547c87f..3846aacb476b552cefddd8774b9a055e353b6ebc 100644 (file)
@@ -921,7 +921,7 @@ struct transport *transport_get(struct remote *remote, const char *url)
        ret->remote = remote;
        helper = remote->foreign_vcs;
 
-       if (!url && remote && remote->url)
+       if (!url && remote->url)
                url = remote->url[0];
        ret->url = url;