summaryrefslogtreecommitdiff
path: root/src/remote.c
diff options
context:
space:
mode:
authorJacques Germishuys <jacquesg@striata.com>2014-04-30 17:46:53 +0200
committerJacques Germishuys <jacquesg@striata.com>2014-04-30 22:58:40 +0200
commit183aa4f8317f5a64f1bc931551a342e6a93ce1c3 (patch)
treef450ebd3787b217f5a9035e46af5e6516ee70035 /src/remote.c
parent6b05240ceaf4df7bbb4806f6827f0314db6a5a91 (diff)
downloadlibgit2-183aa4f8317f5a64f1bc931551a342e6a93ce1c3.tar.gz
Check for NULL before passing it to vsnprintf
Diffstat (limited to 'src/remote.c')
-rw-r--r--src/remote.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/remote.c b/src/remote.c
index ea638e373..be7198a98 100644
--- a/src/remote.c
+++ b/src/remote.c
@@ -73,7 +73,7 @@ static int ensure_remote_name_is_valid(const char *name)
if (!git_remote_is_valid_name(name)) {
giterr_set(
GITERR_CONFIG,
- "'%s' is not a valid remote name.", name);
+ "'%s' is not a valid remote name.", name ? name : "(null)");
error = GIT_EINVALIDSPEC;
}