From 9c4f0d3a6e36f8901e3a85be6269b9ec652b8eea Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 28 Sep 2008 00:36:03 -0700 Subject: songvec_free => songvec_destroy "free" implies the songvec structure itself is freed, which is not the case. --- src/directory.c | 2 +- src/songvec.c | 2 +- src/songvec.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/directory.c b/src/directory.c index 0e7933328..8dff8156e 100644 --- a/src/directory.c +++ b/src/directory.c @@ -221,7 +221,7 @@ static Directory *newDirectory(const char *dirname, Directory * parent) static void freeDirectory(Directory * directory) { freeDirectoryList(directory->subDirectories); - songvec_free(&directory->songs); + songvec_destroy(&directory->songs); if (directory->path) free(directory->path); free(directory); diff --git a/src/songvec.c b/src/songvec.c index 842e7afcd..7ce1285f6 100644 --- a/src/songvec.c +++ b/src/songvec.c @@ -59,7 +59,7 @@ void songvec_add(struct songvec *sv, Song *add) sv->base[sv->nr - 1] = add; } -void songvec_free(struct songvec *sv) +void songvec_destroy(struct songvec *sv) { if (sv->base) { free(sv->base); diff --git a/src/songvec.h b/src/songvec.h index abbc9365b..b823724e7 100644 --- a/src/songvec.h +++ b/src/songvec.h @@ -17,7 +17,7 @@ int songvec_delete(struct songvec *sv, Song *del); void songvec_add(struct songvec *sv, Song *add); -void songvec_free(struct songvec *sv); +void songvec_destroy(struct songvec *sv); int songvec_write(struct songvec *sv, int fd, int extra); -- cgit v1.2.3