From 36eba830fc097279f568e801b2d2a35a08004717 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 5 Oct 2008 17:38:15 -0700 Subject: song: use flex arrays to store song->url Reduce the number of allocations we make, so there's less pressure on the allocator and less overhead to keep track of the allocations in. --- src/directory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/directory.c') diff --git a/src/directory.c b/src/directory.c index 54f1af09c..de4532e75 100644 --- a/src/directory.c +++ b/src/directory.c @@ -296,7 +296,7 @@ removeDeletedFromDirectory(char *path_max_tmp, Directory * directory) for (i = sv->nr; --i >= 0; ) { /* cleaner deletes if we go backwards */ Song *song = sv->base[i]; - if (!song || !song->url) + if (!song || !*song->url) continue; /* does this happen?, perhaps assert() */ if (dirname) -- cgit v1.2.3