string-list: remove print_string_list from string-list's API
PATCH 1/1 string-list: remove print_string_list from string-list's API
print_string_list routine has no callers anywhere.
Signed-off-by Alexander Kuleshov <[email protected]>
--- Documentation/technical/api-string-list.txt | 6 ------ string-list.c | 10 ---------- string-list.h | 1 - 3 files changed, 17 deletions(-)
Documentation/technical/api-string-list.txt +0 -6
@@ -87,12 +87,6 @@ Functions call free() on the util members of any items that have to be deleted. Preserve the order of the items that are retained. -`print_string_list`:: - - Dump a string_list to stdout, useful mainly for debugging purposes. It - can take an optional header argument and it writes out the - string-pointer pairs of the string_list, each one in its own line. - `string_list_clear`:: Free a string_list. The `string` pointer of the items will be freed in
string-list.c +0 -10
@@ -182,16 +182,6 @@ void string_list_clear_func(struct string_list *list, string_list_clear_func_t c list->nr = list->alloc =0 ; } - -void print_string_list (const struct string_list *p,const char *text) -{ -int i; -if ( text ) -printf ("%s\n" , text); -for (i =0 ; i < p->nr; i++) -printf ("%s:%p\n" , p->items[i].string, p->items[i].util); -} -struct string_list_item *string_list_append_nodup (struct string_list *list,char *string) {
string-list.h +0 -1
@@ -20,7 +20,6 @@ struct string_list {void string_list_init (struct string_list *list,int strdup_strings); -void print_string_list (const struct string_list *p,const char *text);void string_list_clear (struct string_list *list,int free_util);/* Use this function to call a custom clear function on each util pointer */
Signature · 1 line
2.3.0.rc0.315.g0e14eda
Maybe need to add comments for print_string_list, for preventing patches like this?
2015-01-15 23:56 GMT+06:00 Junio C Hamano <[email protected]>:
Quoted 7 lines
Quoted 3 lines · Alexander Kuleshov
print_string_listroutine has no callers anywhere.Signed-off-by Alexander Kuleshov <[email protected]>http://thread.gmane.org/gmane.comp.version-control.git/262439
Signature · 2 lines
_________________________ 0xAX