[libgit2-glib/wip/development: 4/14] Fix ggit_remote_new
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgit2-glib/wip/development: 4/14] Fix ggit_remote_new
- Date: Sat, 26 Apr 2014 19:50:39 +0000 (UTC)
commit 4666ec8247494ec3d83ab06adb790731ff84eab7
Author: Ignacio Casal Quinteiro <icq gnome org>
Date: Sat Apr 26 16:09:48 2014 +0200
Fix ggit_remote_new
libgit2-glib/ggit-remote.c | 10 +++++-----
libgit2-glib/ggit-remote.h | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/libgit2-glib/ggit-remote.c b/libgit2-glib/ggit-remote.c
index 816c04a..9855924 100644
--- a/libgit2-glib/ggit-remote.c
+++ b/libgit2-glib/ggit-remote.c
@@ -170,8 +170,8 @@ ggit_remote_init (GgitRemote *self)
/**
* ggit_remote_new:
* @repository: a #GgitRepository.
+ * @name: the remote's name.
* @url: the remote repository's URL.
- * @fetch_spec: the fetch refspec to use for this remote.
* @error: a #GError for error reporting, or %NULL.
*
* Creates a remote with the default refspecs in memory. You can use
@@ -181,19 +181,19 @@ ggit_remote_init (GgitRemote *self)
*/
GgitRemote *
ggit_remote_new (GgitRepository *repository,
+ const gchar *name,
const gchar *url,
- const gchar *fetch_spec,
GError **error)
{
gint ret;
git_remote *remote;
g_return_val_if_fail (GGIT_IS_REPOSITORY (repository), NULL);
+ g_return_val_if_fail (name != NULL, NULL);
g_return_val_if_fail (url != NULL, NULL);
- g_return_val_if_fail (fetch_spec != NULL, NULL);
- ret = git_remote_create_inmemory (&remote, _ggit_native_get (repository),
- url, fetch_spec);
+ ret = git_remote_create (&remote, _ggit_native_get (repository),
+ name, url);
if (ret != GIT_OK)
{
diff --git a/libgit2-glib/ggit-remote.h b/libgit2-glib/ggit-remote.h
index 0a6093d..2b2f6f5 100644
--- a/libgit2-glib/ggit-remote.h
+++ b/libgit2-glib/ggit-remote.h
@@ -71,8 +71,8 @@ const gchar *ggit_remote_head_get_name (GgitRemoteHead *remote_
GgitRemote *_ggit_remote_wrap (git_remote *remote);
GgitRemote *ggit_remote_new (GgitRepository *repository,
+ const gchar *name,
const gchar *url,
- const gchar *fetch_spec,
GError **error);
void ggit_remote_save (GgitRemote *remote,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]