Update of /cvsroot/gtkpod/libgpod/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18175/src
Modified Files: ithumb-writer.c Log Message: * src/ithumb-writer.c: create Artwork directory when attempting to write to it. Index: ithumb-writer.c =================================================================== RCS file: /cvsroot/gtkpod/libgpod/src/ithumb-writer.c,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- ithumb-writer.c 4 Dec 2005 10:26:14 -0000 1.9 +++ ithumb-writer.c 9 Dec 2005 14:54:58 -0000 1.10 @@ -120,6 +120,15 @@ gchar *path; paths[2] = NULL; path = itdb_resolve_path (mount_point, (const char **)paths); + if (path == NULL) + { /* attempt to create directory */ + gchar *pth = g_build_filename (mount_point, + paths[0], path[1], NULL); + mkdir (pth, 0777); + g_free (pth); + path = itdb_resolve_path (mount_point, + (const char **)paths); + } if (path) { filename = g_build_filename (path, buf, NULL); ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click _______________________________________________ gtkpod-cvs2 mailing list gtkpod-cvs2@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2