Skip to content

Commit d97f0a2

Browse files
committed
theme: minor simplification
1 parent 917714f commit d97f0a2

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/theme.c

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -239,13 +239,10 @@ theme_free_vector(struct themes *themes)
239239
{
240240
for (int i = 0; i < themes->nr; ++i) {
241241
struct theme *theme = themes->data + i;
242-
if (theme->name) {
243-
free(theme->name);
244-
}
245-
if (theme->path) {
246-
free(theme->path);
247-
}
242+
free(theme->name);
243+
free(theme->path);
248244
}
249245
free(themes->data);
246+
themes->data = NULL;
250247
}
251248

0 commit comments

Comments
 (0)