Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetr Baudis <pasky@suse.cz>2006-07-28 01:56:14 +0400
committerJunio C Hamano <junkio@cox.net>2006-07-28 06:33:48 +0400
commitc6b69bdbc1b0b914aa0d1e59a29305fce82d6f06 (patch)
tree24fd88a7754cbeacfec51ce02b2d445ad86450d2 /fetch.c
parentc2c487cf3a6c37bc9b4e3f0e10ad08d9ce048404 (diff)
Make pull() take some implicit data as explicit arguments
Currently it's a bit weird that pull() takes a single argument describing the commit but takes the write_ref from a global variable. This makes it take that as a parameter as well, which might be nicer for the libification in the future, but especially it will make for nicer code when we implement pull()ing multiple commits at once. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'fetch.c')
-rw-r--r--fetch.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fetch.c b/fetch.c
index 989d7a4788..3255cc6250 100644
--- a/fetch.c
+++ b/fetch.c
@@ -8,9 +8,6 @@
#include "blob.h"
#include "refs.h"
-const char *write_ref = NULL;
-const char *write_ref_log_details = NULL;
-
int get_tree = 0;
int get_history = 0;
int get_all = 0;
@@ -213,7 +210,8 @@ static int mark_complete(const char *path, const unsigned char *sha1)
return 0;
}
-int pull(char *target)
+int pull(char *target, const char *write_ref,
+ const char *write_ref_log_details)
{
struct ref_lock *lock = NULL;
unsigned char sha1[20];