summaryrefslogtreecommitdiff
path: root/transport.h
diff options
context:
space:
mode:
authorDaniel Barkalow <barkalow@iabervon.org>2008-04-17 23:32:22 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-05-05 00:41:44 (GMT)
commit2d5c298f91b4b76a8b51b9b66283ef5a872736a0 (patch)
treeb24f7622fba5d782fe42c94d4f17fd7bd5080808 /transport.h
parentc697ad143ba1ff58b29e7efe149d244d4b7010a5 (diff)
downloadgit-2d5c298f91b4b76a8b51b9b66283ef5a872736a0.zip
git-2d5c298f91b4b76a8b51b9b66283ef5a872736a0.tar.gz
git-2d5c298f91b4b76a8b51b9b66283ef5a872736a0.tar.bz2
Mark the list of refs to fetch as const
Fetching the objects doesn't actually modify the list in any of the code paths, so this will allow code that fetches the entire (const) list of available refs to just pass the list in directly. Signed-off-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport.h')
-rw-r--r--transport.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/transport.h b/transport.h
index 8abfc0a..d0b5205 100644
--- a/transport.h
+++ b/transport.h
@@ -19,7 +19,7 @@ struct transport {
const char *value);
struct ref *(*get_refs_list)(struct transport *transport);
- int (*fetch)(struct transport *transport, int refs_nr, struct ref **refs);
+ int (*fetch)(struct transport *transport, int refs_nr, const struct ref **refs);
int (*push)(struct transport *connection, int refspec_nr, const char **refspec, int flags);
int (*disconnect)(struct transport *connection);
@@ -68,7 +68,7 @@ int transport_push(struct transport *connection,
const struct ref *transport_get_remote_refs(struct transport *transport);
-int transport_fetch_refs(struct transport *transport, struct ref *refs);
+int transport_fetch_refs(struct transport *transport, const struct ref *refs);
void transport_unlock_pack(struct transport *transport);
int transport_disconnect(struct transport *transport);