Junio C Hamano <gitster@xxxxxxxxx> writes: > Carlos Martín Nieto <cmn@xxxxxxxx> writes: > >> Move the body of remote_find_tracking to a new function query_refspecs >> which does the same (find a refspec that matches and apply the >> transformation) but explicitly wants the list of refspecs. >> >> Make remote_find_tracking and apply_refspecs use query_refspecs. >> >> Signed-off-by: Carlos Martín Nieto <cmn@xxxxxxxx> >> --- >> remote.c | 70 ++++++++++++++++++++++++++++++------------------------------- >> 1 files changed, 34 insertions(+), 36 deletions(-) > > Looks very sensible, especially knowing what you want to do in the next > patch ;-). > > Thanks. I notice that before this update, passing a refspec[] with an element that lacks its dst side to apply_refspecs() would have segfaulted but with this update such an element in the refspec[] will simply be ignored. This helper function was added in 72ff894 (Allow helper to map private ref names into normal names, 2009-11-18) for transport-helper's use. I am sure the change will not introduce a regression due to this skippage (the code without this patch would have simply crashed with such an input anyway), but I thought people involved in the transport layer may want to know. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html