Revision: 2047
          http://gtkpod.svn.sourceforge.net/gtkpod/?rev=2047&view=rev
Author:   teuf
Date:     2008-07-10 09:28:00 -0700 (Thu, 10 Jul 2008)

Log Message:
-----------
Don't try to write ArtworkDB/PhotoDB when we fail to write ithmb files

Modified Paths:
--------------
    libgpod/trunk/ChangeLog
    libgpod/trunk/src/db-artwork-writer.c

Modified: libgpod/trunk/ChangeLog
===================================================================
--- libgpod/trunk/ChangeLog     2008-07-09 19:46:57 UTC (rev 2046)
+++ libgpod/trunk/ChangeLog     2008-07-10 16:28:00 UTC (rev 2047)
@@ -1,3 +1,8 @@
+2008-07-10  Christophe Fergeau <[EMAIL PROTECTED]>
+
+       * src/db-artwork-writer.c: if we fail to write ithmb files for some
+       reason, don't go on trying to write the ArtworkDB/PhotoDB as well
+
 2008-07-09  Todd Zullinger  <tmzullinger at users.sourceforge.net>
 
        * po/POTFILES.in: add src/itdb_thumb.c

Modified: libgpod/trunk/src/db-artwork-writer.c
===================================================================
--- libgpod/trunk/src/db-artwork-writer.c       2008-07-09 19:46:57 UTC (rev 
2046)
+++ libgpod/trunk/src/db-artwork-writer.c       2008-07-10 16:28:00 UTC (rev 
2047)
@@ -1151,6 +1151,7 @@
        char *filename;
        int id_max;
        Itdb_DB db;
+       int status;
 
        db.db_type = DB_TYPE_ITUNES;
        db.db.itdb = itdb;
@@ -1160,7 +1161,10 @@
        /* First, let's write the .ithmb files, this will create the
         * various thumbnails as well */
 
-       itdb_write_ithumb_files (&db);
+       status = itdb_write_ithumb_files (&db);
+       if (status != 0) {
+               return -1;
+       }
 
        filename = ipod_db_get_artwork_db_path (itdb_get_mountpoint (itdb));
        if (filename == NULL) {
@@ -1200,13 +1204,17 @@
        char *filename;
        int id_max;
        Itdb_DB db;
+       int status;
 
        db.db_type = DB_TYPE_PHOTO;
        db.db.photodb = photodb;
 
        filename = ipod_db_get_photos_db_path (db_get_mountpoint (&db));
 
-       itdb_write_ithumb_files (&db);
+       status = itdb_write_ithumb_files (&db);
+       if (status != 0) {
+               return -1;
+       }
 
        if (filename == NULL) {
                return -1;


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
gtkpod-cvs2 mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2

Reply via email to