From 0473f3ea76c57be8b20e1fae628ec7ae7f04b5f7 Mon Sep 17 00:00:00 2001 From: Warren Dukes Date: Fri, 12 Nov 2004 17:38:52 +0000 Subject: don't store only relative paths in the directory structure, its probably not worth the savings in memory for the extra cpu it requires git-svn-id: https://svn.musicpd.org/mpd/trunk@2630 09075e82-0dd4-0310-85a5-a0d7c8717e4f --- src/directory.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/directory.h') diff --git a/src/directory.h b/src/directory.h index cb587234f..a0a615265 100644 --- a/src/directory.h +++ b/src/directory.h @@ -35,7 +35,7 @@ typedef struct _DirectoryStat { } DirectoryStat; typedef struct _Directory { - char * name; + char * path; DirectoryList * subDirectories; SongList * songs; struct _Directory * parent; @@ -76,7 +76,8 @@ int traverseAllIn(FILE * fp, char * name, void * data); /* don't free this */ -char * getDirectoryPath(Directory * dir); +/*char * getDirectoryPath(Directory * dir);*/ +#define getDirectoryPath(dir) ((dir && dir->path) ? dir->path : "") /* free the string that is returned */ char * catDirAndFileName(Directory * dir, char * filename); -- cgit v1.2.3