[Python-apps-commits] r5339 - in packages/sonata/trunk/debian (4 files)

nijel at users.alioth.debian.org nijel at users.alioth.debian.org
Thu Jun 3 07:58:38 UTC 2010


    Date: Thursday, June 3, 2010 @ 07:58:27
  Author: nijel
Revision: 5339

Fixed crash when it is not possible to get list of albums (Closes: #572262).

Added:
  packages/sonata/trunk/debian/patches/
  packages/sonata/trunk/debian/patches/fix-cras-on-no-albums.patch
  packages/sonata/trunk/debian/patches/series
Modified:
  packages/sonata/trunk/debian/changelog

Modified: packages/sonata/trunk/debian/changelog
===================================================================
--- packages/sonata/trunk/debian/changelog	2010-06-03 07:50:34 UTC (rev 5338)
+++ packages/sonata/trunk/debian/changelog	2010-06-03 07:58:27 UTC (rev 5339)
@@ -1,8 +1,9 @@
 sonata (1.6.2.1-3) UNRELEASED; urgency=low
 
   * Again recommend eggtrayicon because it provides more features (see: #560979).
+  * Fixed crash when it is not possible to get list of albums (Closes: #572262).
 
- -- Michal ÄŒihaÅ™ <nijel at debian.org>  Sun, 03 Jan 2010 14:55:19 +0100
+ -- Michal ÄŒihaÅ™ <nijel at debian.org>  Thu, 03 Jun 2010 09:57:50 +0200
 
 sonata (1.6.2.1-2) unstable; urgency=low
 

Added: packages/sonata/trunk/debian/patches/fix-cras-on-no-albums.patch
===================================================================
--- packages/sonata/trunk/debian/patches/fix-cras-on-no-albums.patch	                        (rev 0)
+++ packages/sonata/trunk/debian/patches/fix-cras-on-no-albums.patch	2010-06-03 07:58:27 UTC (rev 5339)
@@ -0,0 +1,16 @@
+From: Michal ÄŒihaÅ™ <nijel at debian.org>
+Subject: Fix crash on adding playlist
+    This actually happens when it is not possible to get related albums and
+    self.album_return_artist_and_tracks returns (None, None)
+Forwarded: https://developer.berlios.de/patch/index.php?func=detailpatch&patch_id=3004&group_id=7323
+--- a/sonata/info.py
++++ b/sonata/info.py
+@@ -289,7 +289,7 @@
+ 					if album is not None:
+ 						albuminfo = album + "\n"
+ 					playtime = 0
+-					if len(tracks) > 0:
++					if tracks is not None and len(tracks) > 0:
+ 						tracks.sort(key=lambda x: int(mpdh.getnum(x, 'track', '0', True, 0)))
+ 						for track in tracks:
+ 							playtime += int(mpdh.get(track, 'time', 0))

Added: packages/sonata/trunk/debian/patches/series
===================================================================
--- packages/sonata/trunk/debian/patches/series	                        (rev 0)
+++ packages/sonata/trunk/debian/patches/series	2010-06-03 07:58:27 UTC (rev 5339)
@@ -0,0 +1 @@
+fix-cras-on-no-albums.patch




More information about the Python-apps-commits mailing list