Hash :
42ea35c0
Author :
Date :
2012-05-01T22:25:43
remote: don't free transport on disconnect
Currently, git_remote_disconnect not only closes the connection but also
frees the underlying transport object, making it impossible to write
code like
// fetch stuff
git_remote_download()
// close connection
git_remote_disconnect()
// call user provided callback for each ref
git_remote_update_tips(remote, callback)
because remote->refs points to references owned by the transport object.
This means, we have an idling connection while running the callback for
each reference.
Instead, allow immediate disconnect and free the transport later in
git_remote_free().