widgets: clear private struct
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
bd47652fe0
commit
c0f75c2ed8
|
@ -112,6 +112,8 @@ graph_plot_add(graph_data_t *d, const char *title)
|
||||||
{
|
{
|
||||||
plot_t plot;
|
plot_t plot;
|
||||||
|
|
||||||
|
p_clear(&plot, 1);
|
||||||
|
|
||||||
plot.title = a_strdup(title);
|
plot.title = a_strdup(title);
|
||||||
plot.values = p_new(float, d->size);
|
plot.values = p_new(float, d->size);
|
||||||
plot.lines = p_new(int, d->size);
|
plot.lines = p_new(int, d->size);
|
||||||
|
|
|
@ -95,6 +95,8 @@ progressbar_bar_add(progressbar_data_t *d, const char *title)
|
||||||
{
|
{
|
||||||
bar_t bar;
|
bar_t bar;
|
||||||
|
|
||||||
|
p_clear(&bar, 1);
|
||||||
|
|
||||||
bar.title = a_strdup(title);
|
bar.title = a_strdup(title);
|
||||||
bar.fg = globalconf.colors.fg;
|
bar.fg = globalconf.colors.fg;
|
||||||
bar.fg_off = globalconf.colors.bg;
|
bar.fg_off = globalconf.colors.bg;
|
||||||
|
|
Loading…
Reference in New Issue