Hook up iTunes library scanner

This commit is contained in:
Julien BLACHE 2009-11-22 11:17:33 +01:00
parent 3154416415
commit 6114c31c61
2 changed files with 15 additions and 6 deletions

View File

@ -276,11 +276,11 @@ process_playlist(char *file)
if (ext) if (ext)
{ {
if (strcmp(ext, ".m3u") == 0) if (strcmp(ext, ".m3u") == 0)
{ scan_m3u_playlist(file);
scan_m3u_playlist(file); #ifdef ITUNES
else if (strcmp(ext, ".xml") == 0)
return; scan_itunes_itml(file);
} #endif
} }
} }
@ -347,7 +347,11 @@ process_file(char *file, time_t mtime, off_t size, int compilation, int flags)
ext = strrchr(file, '.'); ext = strrchr(file, '.');
if (ext) if (ext)
{ {
if (strcmp(ext, ".m3u") == 0) if ((strcmp(ext, ".m3u") == 0)
#ifdef ITUNES
|| (strcmp(ext, ".xml") == 0)
#endif
)
{ {
if (flags & F_SCAN_BULK) if (flags & F_SCAN_BULK)
defer_playlist(file); defer_playlist(file);

View File

@ -20,4 +20,9 @@ scan_url_file(char *file, struct media_file_info *mfi);
void void
scan_m3u_playlist(char *file); scan_m3u_playlist(char *file);
#ifdef ITUNES
void
scan_itunes_itml(char *file);
#endif
#endif /* !__FILESCANNER_H__ */ #endif /* !__FILESCANNER_H__ */