Re: [PATCH v3 1/3] string-list: add string_list initialiser helper functions

2014-06-23 Thread Tanay Abhra
On 06/23/2014 05:36 AM, Torsten Bögershausen wrote: > If we look at the definition below: > struct string_list { > struct string_list_item *items; > unsigned int nr, alloc; > unsigned int strdup_strings:1; > compare_strings_fn cmp; /* NULL uses strcmp() */ > I think a simple

Re: [PATCH v3 1/3] string-list: add string_list initialiser helper functions

2014-06-23 Thread Torsten Bögershausen
On 2014-06-23 12.11, Tanay Abhra wrote: > The string-list API has STRING_LIST_INIT_* macros to be used > to define variables with initialisers, but lacks functions > to initialise an uninitialised piece of memory to be used as > a string-list at the run-time. > Introduce string_list_init_{dup,nodup

[PATCH v3 1/3] string-list: add string_list initialiser helper functions

2014-06-23 Thread Tanay Abhra
The string-list API has STRING_LIST_INIT_* macros to be used to define variables with initialisers, but lacks functions to initialise an uninitialised piece of memory to be used as a string-list at the run-time. Introduce string_list_init_{dup,nodup}() functions for that. Signed-off-by: Tanay Abhr