From 262eec23fe7377a9eecf9e724fa1aba945b3162a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20Mart=C3=ADn=20Nieto?= Date: Tue, 30 Sep 2014 16:07:30 +0200 Subject: remote: accept a repository and remote name for deletion We don't need the remote loaded, and the function extracted both of these from the git_remote in order to do its work, so let's remote a step and not ask for the loaded remote at all. This fixes #2390. --- include/git2/remote.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'include/git2') diff --git a/include/git2/remote.h b/include/git2/remote.h index 055f5e517..6c3eb391b 100644 --- a/include/git2/remote.h +++ b/include/git2/remote.h @@ -596,10 +596,11 @@ GIT_EXTERN(int) git_remote_is_valid_name(const char *remote_name); * All remote-tracking branches and configuration settings * for the remote will be removed. * -* @param remote A valid remote +* @param repo the repository in which to act +* @param name the name of the remove to delete * @return 0 on success, or an error code. */ -GIT_EXTERN(int) git_remote_delete(git_remote *remote); +GIT_EXTERN(int) git_remote_delete(git_repository *repo, const char *name); /** * Retrieve the name of the remote's default branch -- cgit v1.2.1