Re: [PATCH 2/3] connect.c: save symref info from server capabilities

2013-09-06 Thread Junio C Hamano
Andreas Krey writes: > Can I assume that the only capability list is always on the > first ref sent (as it is now)? The capability list _could_ be sent more than once, and the receiving end is prepared to accept such a stream. Everything learned from an older capability list needs to be forgot

Re: [PATCH 2/3] connect.c: save symref info from server capabilities

2013-09-06 Thread Andreas Krey
On Fri, 06 Sep 2013 10:56:51 +, Junio C Hamano wrote: > Andreas Krey writes: > ... > > + if (symref) { > > + ref->symref = xcalloc(symref_len + 1, 1); > > + strncpy(ref->symref, symref, symref_len); > > + } ... > > This looks utterly wr

Re: [PATCH 2/3] connect.c: save symref info from server capabilities

2013-09-06 Thread Junio C Hamano
Andreas Krey writes: > Signed-off-by: Andreas Krey > --- > connect.c | 11 +-- > 1 file changed, 9 insertions(+), 2 deletions(-) > > diff --git a/connect.c b/connect.c > index a0783d4..98c4868 100644 > --- a/connect.c > +++ b/connect.c > @@ -72,8 +72,8 @@ struct ref **get_remote_heads(i

[PATCH 2/3] connect.c: save symref info from server capabilities

2013-09-06 Thread Andreas Krey
Signed-off-by: Andreas Krey --- connect.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/connect.c b/connect.c index a0783d4..98c4868 100644 --- a/connect.c +++ b/connect.c @@ -72,8 +72,8 @@ struct ref **get_remote_heads(int in, char *src_buf, size_t src_len,