no point in tallying stats on writeDirectoryDB anymore

git-svn-id: https://svn.musicpd.org/mpd/trunk@774 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
Warren Dukes 2004-04-15 15:25:06 +00:00
parent 55789de546
commit 0b7d9b2dec

View File

@ -789,8 +789,6 @@ int writeDirectoryDB() {
deleteEmptyDirectoriesInDirectory(mp3rootDirectory);
sortDirectory(mp3rootDirectory);
stats.numberOfSongs = countSongsIn(stderr,NULL);
stats.dbPlayTime = sumSongTimesIn(stderr,NULL);
while(!(fp=fopen(directorydb,"w")) && errno==EINTR);
if(!fp) return -1;
@ -1128,6 +1126,8 @@ unsigned long sumSongTimesIn(FILE * fp, char * name) {
void initMp3Directory() {
mp3rootDirectory = newDirectory(NULL,0);
exploreDirectory(mp3rootDirectory);
stats.numberOfSongs = countSongsIn(stderr,NULL);
stats.dbPlayTime = sumSongTimesIn(stderr,NULL);
}
Song * getSongDetails(char * file, char ** shortnameRet,