Thread (7 messages) flat view 7 messages, 1 author, 2016-06-15
DORMANTno replies

Revision v1 of 2 in this series.

Revisions (2)
  1. v1 current
  2. v2 [diff vs current]

[PATCH 1/6] string_list: Fix argument order for print_string_list

From: Julian Phillips <hidden>
Date: 2016-06-15 22:48:33
Subsystem: the rest · Maintainer: Linus Torvalds

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 <redacted>
---
 string-list.c |    2 +-
 string-list.h |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/string-list.c b/string-list.c
index c9ad7fc..b7e57a4 100644
--- a/string-list.c
+++ b/string-list.c
@@ -139,7 +139,7 @@ void string_list_clear_func(struct string_list *list, string_list_clear_func_t c
 }
 
 
-void print_string_list(const char *text, const struct string_list *p)
+void print_string_list(const struct string_list *p, const char *text)
 {
 	int i;
 	if ( text )
diff --git a/string-list.h b/string-list.h
index 63b69c8..de29dcd 100644
--- a/string-list.h
+++ b/string-list.h
@@ -12,7 +12,7 @@ struct string_list
 	unsigned int strdup_strings:1;
 };
 
-void print_string_list(const char *text, const struct string_list *p);
+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 */
-- 
1.7.0.2
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help