X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=builtin-push.c;h=5633f0ade49f7c845665b7aab202be18a8cc9d8d;hb=cc8eb6407e88a46da6d41e18cffed3878f2c53cf;hp=5df66081a6ff0ca5087ff9a2ac4042d8ec651499;hpb=d4556c49eef293594a61fb8697b93b1d83904dc2;p=git.git diff --git a/builtin-push.c b/builtin-push.c index 5df66081a..5633f0ade 100644 --- a/builtin-push.c +++ b/builtin-push.c @@ -52,7 +52,7 @@ static void set_refspecs(const char **refs, int nr) } else if (deleterefs && !strchr(ref, ':')) { char *delref; int len = strlen(ref)+1; - delref = xmalloc(len); + delref = xmalloc(len+1); strcpy(delref, ":"); strcat(delref, ref); ref = delref;