Re: [PATCH 5/7] remote-helpers: add support for an export command
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 1, 2010, 04:54 UTC
- Message-ID
- <7v634bsrg5.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <1269881309-19690-6-git-send-email-srabbelier@gmail.com>
Sverre Rabbelier <srabbelier@gmail.com> writes:
Show 5 quoted lines
> --- > > This complements the 'import' capability, making it possible > to use remote-helpers with only fast-import/fast-exports > streams.
I've queued this in 'pu' only to say "I've seen it", but I suspect that this has to wait until after 1.7.1. I've been trying to shoot for 6-8 week cycle as originally envisioned, and if things go as planned, post 1.7.1 cycle opens around mid April.
Show 17 quoted lines
> + for(ref = remote_refs; ref; ref = ref->next) {
> + char* private;
> + unsigned char sha1[20];
> +
> +
> + if(data->refspecs)
> + private = apply_refspecs(data->refspecs, data->refspec_nr, ref->name);
> +
> + if(private && !get_sha1(private, sha1))
> + {
> + strbuf_addf(&buf, "^%s", private);
> + string_list_append(strbuf_detach(&buf, NULL), &revlist_args);
> + }
> +
> + string_list_append(ref->name, &revlist_args);
> +
> + }What's happening here? Style violations aside, it appears that "private" is accessed uninitialized when data->refspecs is NULL.