[PATCH] stringlist: string_list_contains can use a const string

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Jan Luebbe <jlu@xxxxxxxxxxxxxx>
---
 include/stringlist.h | 2 +-
 lib/stringlist.c     | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/stringlist.h b/include/stringlist.h
index 127998cb6e21..2e2addf98f19 100644
--- a/include/stringlist.h
+++ b/include/stringlist.h
@@ -11,7 +11,7 @@ struct string_list {
 int string_list_add(struct string_list *sl, char *str);
 int string_list_add_asprintf(struct string_list *sl, const char *fmt, ...);
 int string_list_add_sorted(struct string_list *sl, char *str);
-int string_list_contains(struct string_list *sl, char *str);
+int string_list_contains(struct string_list *sl, const char *str);
 void string_list_print_by_column(struct string_list *sl);
 
 static inline void string_list_init(struct string_list *sl)
diff --git a/lib/stringlist.c b/lib/stringlist.c
index cc84944f73b3..57801b3bb04d 100644
--- a/lib/stringlist.c
+++ b/lib/stringlist.c
@@ -60,7 +60,7 @@ int string_list_add_sorted(struct string_list *sl, char *str)
 	return 0;
 }
 
-int string_list_contains(struct string_list *sl, char *str)
+int string_list_contains(struct string_list *sl, const char *str)
 {
 	struct string_list *entry;
 
-- 
2.1.1


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox




[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux