@matheusbsbs / matheus-bagliano / commits / d1ab157759
Fork 0

arguments cleanup and some formatting

Signed-off-by: Alex Riesen <ariesen@harmanbecker.com> Signed-off-by: Junio C Hamano <junkio@cox.net>

Alex Riesen committed Nov 22, 2005 at 15:59 UTC d1ab157759f0738a13bfb04bca8c436814913d4b
1 file changed +8 -7
pack-redundant.c
+8 -7
@@ -149,8 +149,9 @@ static inline struct llist_item * llist_insert_sorted_unique(struct llist *list,
149 }
150
151 /* returns a pointer to an item in front of sha1 */
152 -static inline struct llist_item * llist_sorted_remove(struct llist *list, char *sha1,
153 - struct llist_item *hint)
152 +static inline struct llist_item * llist_sorted_remove(struct llist *list,
153 + const char *sha1,
154 + struct llist_item *hint)
155 {
156 struct llist_item *prev, *l;
157
@@ -218,10 +219,11 @@ static inline size_t pack_list_size(struct pack_list *pl)
219 return ret;
220 }
221
221 -static struct pack_list * pack_list_difference(struct pack_list *A,
222 - struct pack_list *B)
222 +static struct pack_list * pack_list_difference(const struct pack_list *A,
223 + const struct pack_list *B)
224 {
224 - struct pack_list *ret, *pl;
225 + struct pack_list *ret;
226 + const struct pack_list *pl;
227
228 if (A == NULL)
229 return NULL;
@@ -350,8 +352,7 @@ static int is_superset(struct pack_list *pl, struct llist *list)
352 diff = llist_copy(list);
353
354 while (pl) {
353 - llist_sorted_difference_inplace(diff,
354 - pl->all_objects);
355 + llist_sorted_difference_inplace(diff, pl->all_objects);
356 if (diff->size == 0) { /* we're done */
357 llist_free(diff);
358 return 1;