Rename item_list_{init,make}()
This commit is contained in:
parent
3ff7867e30
commit
f71eee66bd
11
nncmpp.c
11
nncmpp.c
|
@ -459,11 +459,12 @@ struct item_list
|
||||||
size_t alloc; ///< Allocated items
|
size_t alloc; ///< Allocated items
|
||||||
};
|
};
|
||||||
|
|
||||||
static void
|
static struct item_list
|
||||||
item_list_init (struct item_list *self)
|
item_list_make (void)
|
||||||
{
|
{
|
||||||
memset (self, 0, sizeof *self);
|
struct item_list self = {};
|
||||||
self->items = xcalloc (sizeof *self->items, (self->alloc = 16));
|
self.items = xcalloc (sizeof *self.items, (self.alloc = 16));
|
||||||
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -819,7 +820,7 @@ app_init_context (void)
|
||||||
g.client = mpd_client_make (&g.poller);
|
g.client = mpd_client_make (&g.poller);
|
||||||
g.config = config_make ();
|
g.config = config_make ();
|
||||||
g.streams = strv_make ();
|
g.streams = strv_make ();
|
||||||
item_list_init (&g.playlist);
|
g.playlist = item_list_make ();
|
||||||
|
|
||||||
g.playback_info = str_map_make (free);
|
g.playback_info = str_map_make (free);
|
||||||
g.playback_info.key_xfrm = tolower_ascii_strxfrm;
|
g.playback_info.key_xfrm = tolower_ascii_strxfrm;
|
||||||
|
|
Loading…
Reference in New Issue