Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Diff of /sql.c [6820d0] .. [c5bb5c] Maximize Restore

  Switch to side-by-side view

--- a/sql.c
+++ b/sql.c
@@ -216,13 +216,19 @@
 		return 5;
 	if (db_vers < 6)
 	{
-		DPRINTF(E_WARN, L_DB_SQL, "Updating DB version to v%d.\n", DB_VERSION);
 		ret = sql_exec(db, "CREATE TABLE BOOKMARKS ("
 		                        "ID INTEGER PRIMARY KEY, "
 					"SEC INTEGER)");
 		if( ret != SQLITE_OK )
 			return 6;
 	}
+	if (db_vers < 7)
+	{
+		DPRINTF(E_WARN, L_DB_SQL, "Updating DB version to v%d.\n", DB_VERSION);
+		ret = sql_exec(db, "ALTER TABLE DETAILS ADD rotation INTEGER");
+		if( ret != SQLITE_OK )
+			return 7;
+	}
 	sql_exec(db, "PRAGMA user_version = %d", DB_VERSION);
 
 	return 0;