diff -uNr libgpod-0.4.2/src/db-parse-context.c libgpod-0.4.2-new/src/db-parse-context.c --- libgpod-0.4.2/src/db-parse-context.c Mon Oct 2 09:52:47 2006 +++ libgpod-0.4.2-new/src/db-parse-context.c Sun Feb 11 19:52:19 2007 @@ -23,9 +23,9 @@ */ +#include #include #include -#include #include #include #include diff -uNr libgpod-0.4.2/src/itdb_itunesdb.c libgpod-0.4.2-new/src/itdb_itunesdb.c --- libgpod-0.4.2/src/itdb_itunesdb.c Sun Jan 14 09:28:37 2007 +++ libgpod-0.4.2-new/src/itdb_itunesdb.c Sun Feb 11 19:52:31 2007 @@ -122,8 +122,16 @@ #include #include #include -#include #include + +#ifdef NO_STATVFS +# include +# define statvfs statfs +# define f_frsize f_bsize +#else +# include +#endif + #include #include @@ -132,7 +140,6 @@ #define ITUNESDB_COPYBLK (1024*1024*4) /* blocksize for cp () */ - /* NOTE for developers: Sometimes new MHOD string fields are added by Apple in the @@ -4638,6 +4645,18 @@ } + gboolean haystack (gchar *filetype, gchar **desclist) + { + gchar **dlp; + if (!filetype || !desclist) return FALSE; + for (dlp=desclist; *dlp; ++dlp) + { + if (strstr (filetype, *dlp)) return TRUE; + } + return FALSE; +} + + /** * itdb_shuffle_write_file: * @itdb: the #Itdb_iTunesDB to write to disk @@ -4652,18 +4671,6 @@ gboolean itdb_shuffle_write_file (Itdb_iTunesDB *itdb, const gchar *filename, GError **error) { - auto gboolean haystack (gchar *filetype, gchar **desclist); - gboolean haystack (gchar *filetype, gchar **desclist) - { - gchar **dlp; - if (!filetype || !desclist) return FALSE; - for (dlp=desclist; *dlp; ++dlp) - { - if (strstr (filetype, *dlp)) return TRUE; - } - return FALSE; - } - FExport *fexp; GList *gl; WContents *cts; diff -uNr libgpod-0.4.2/src/itdb_track.c libgpod-0.4.2-new/src/itdb_track.c --- libgpod-0.4.2/src/itdb_track.c Sun Jan 14 10:15:50 2007 +++ libgpod-0.4.2-new/src/itdb_track.c Sun Feb 11 19:52:19 2007 @@ -69,20 +69,11 @@ return track; } +extern gboolean haystack (gchar *filetype, gchar **desclist); + /* Attempt to set some of the unknowns to reasonable defaults */ static void itdb_track_set_defaults (Itdb_Track *tr) { - auto gboolean haystack (gchar *filetype, gchar **desclist); - gboolean haystack (gchar *filetype, gchar **desclist) - { - gchar **dlp; - if (!filetype || !desclist) return FALSE; - for (dlp=desclist; *dlp; ++dlp) - { - if (strstr (filetype, *dlp)) return TRUE; - } - return FALSE; - } gchar *mp3_desc[] = {"MPEG", "MP3", "mpeg", "mp3", NULL}; gchar *mp4_desc[] = {"AAC", "MP4", "aac", "mp4", NULL};