Skip to content

Commit cb944f6

Browse files
qurgitster
authored andcommitted
string_list: Fix argument order for print_string_list
Update the definition and callers of print_string_list to use the string_list as the first argument. This helps make the API easier to use by being more consistent. Signed-off-by: Julian Phillips <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 7c42e39 commit cb944f6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

string-list.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ void string_list_clear_func(struct string_list *list, string_list_clear_func_t c
139139
}
140140

141141

142-
void print_string_list(const char *text, const struct string_list *p)
142+
void print_string_list(const struct string_list *p, const char *text)
143143
{
144144
int i;
145145
if ( text )

string-list.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ struct string_list
1212
unsigned int strdup_strings:1;
1313
};
1414

15-
void print_string_list(const char *text, const struct string_list *p);
15+
void print_string_list(const struct string_list *p, const char *text);
1616
void string_list_clear(struct string_list *list, int free_util);
1717

1818
/* Use this function to call a custom clear function on each util pointer */

0 commit comments

Comments
 (0)