Hello community, here is the log from the commit of package podsleuth for openSUSE:Factory checked in at Mon Jan 12 12:07:47 CET 2009. -------- --- podsleuth/podsleuth.changes 2008-10-26 22:15:18.000000000 +0100 +++ /mounts/work_src_done/STABLE/podsleuth/podsleuth.changes 2008-12-19 21:56:56.000000000 +0100 @@ -1,0 +2,6 @@ +Fri Dec 19 14:54:07 CST 2008 - gburt@suse.de + +- Patch to fix crash getting production info on old models (bgo#564658) +- Patch to fix crash due to duplicate hashtable keys (bnc#430663) + +------------------------------------------------------------------- calling whatdependson for head-i586 New: ---- bgo564658-fix-production-info-crash.diff bnc430663-fix-duplicate-key-crash.diff ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ podsleuth.spec ++++++ --- /var/tmp/diff_new_pack.R25178/_old 2009-01-12 12:06:57.000000000 +0100 +++ /var/tmp/diff_new_pack.R25178/_new 2009-01-12 12:06:57.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package podsleuth (Version 0.6.3) # -# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -20,13 +20,15 @@ Name: podsleuth Version: 0.6.3 -Release: 4 +Release: 5 License: X11/MIT Group: Hardware/Other Summary: PodSleuth provides rich iPod metadata through HAL Url: http://banshee-project.org/PodSleuth Source: %{name}-%{version}.tar.bz2 Patch1: update-model-info-fix-artwork-bug-r64_68.patch +Patch2: bgo564658-fix-production-info-crash.diff +Patch3: bnc430663-fix-duplicate-key-crash.diff AutoReqProv: on PreReq: filesystem BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -64,6 +66,8 @@ %prep %setup -q %patch1 -p0 +%patch2 -p0 +%patch3 -p0 %build %{?env_options} @@ -88,6 +92,9 @@ %{_prefix}/lib/podsleuth/PodSleuth.dll* %changelog +* Fri Dec 19 2008 gburt@suse.de +- Patch to fix crash getting production info on old models (bgo#564658) +- Patch to fix crash due to duplicate hashtable keys (bnc#430663) * Sun Oct 26 2008 gburt@suse.de - Update the model table to include model info for most recently released iPods. ++++++ bgo564658-fix-production-info-crash.diff ++++++ Index: src/PodSleuth.Hal/PodSleuth.HalFrontend/HalClient.cs =================================================================== --- src/PodSleuth.Hal/PodSleuth.HalFrontend/HalClient.cs (revision 68) +++ src/PodSleuth.Hal/PodSleuth.HalFrontend/HalClient.cs (working copy) @@ -200,17 +200,21 @@ private static string GetProductionInfo(Hal.Volume volume) { - string factory_id = volume[HalNamespace + "ipod.production.factory_id"]; - int year = volume.GetPropertyInteger(HalNamespace + "ipod.production.year"); - int week = volume.GetPropertyInteger(HalNamespace + "ipod.production.week"); - int number = volume.GetPropertyInteger(HalNamespace + "ipod.production.number"); - - CultureInfo culture = CultureInfo.CurrentCulture; - DateTime production_date = culture.Calendar.AddWeeks(new DateTime(year, 1, 1), week); - - return String.Format("{0} in {1}, {2} from factory {3}", - number, culture.DateTimeFormat.GetMonthName(production_date.Month), - year, factory_id); + try { + string factory_id = volume[HalNamespace + "ipod.production.factory_id"]; + int year = volume.GetPropertyInteger(HalNamespace + "ipod.production.year"); + int week = volume.GetPropertyInteger(HalNamespace + "ipod.production.week"); + int number = volume.GetPropertyInteger(HalNamespace + "ipod.production.number"); + + CultureInfo culture = CultureInfo.CurrentCulture; + DateTime production_date = culture.Calendar.AddWeeks(new DateTime(year, 1, 1), week); + + return String.Format("{0} in {1}, {2} from factory {3}", + number, culture.DateTimeFormat.GetMonthName(production_date.Month), + year, factory_id); + } catch (Exception) { + return "Unknown"; + } } private static void DumpSleuthableIpod(Hal.Volume volume) Index: ChangeLog =================================================================== --- ChangeLog (revision 68) +++ ChangeLog (working copy) @@ -1,3 +1,8 @@ +2008-12-19 Gabriel Burt <gabriel.burt@gmail.com> + + * src/PodSleuth.Hal/PodSleuth.HalFrontend/HalClient.cs: Fix crasher caused + by production info not being where we expect it (BGO #564658) + 2008-10-01 Gabriel Burt <gabriel.burt@gmail.com> * data/ipod-model-table: Add a lot of new info taken from libgpod. ++++++ bnc430663-fix-duplicate-key-crash.diff ++++++ Index: ChangeLog =================================================================== --- ChangeLog (revision 69) +++ ChangeLog (revision 71) @@ -1,5 +1,15 @@ 2008-12-19 Gabriel Burt <gabriel.burt@gmail.com> + * data/ipod-model-table: Update from libgpod, and extrapolate some SNs + based on the new info. + +2008-12-19 Gabriel Burt <gabriel.burt@gmail.com> + + * src/PodSleuth/PropertyList/PlistDictionary.cs: Ignore duplicate keys in + a dictionary (BNC #430663) + +2008-12-19 Gabriel Burt <gabriel.burt@gmail.com> + * src/PodSleuth.Hal/PodSleuth.HalFrontend/HalClient.cs: Fix crasher caused by production info not being where we expect it (BGO #564658) Index: src/PodSleuth/PropertyList/PlistDictionary.cs =================================================================== --- src/PodSleuth/PropertyList/PlistDictionary.cs (revision 69) +++ src/PodSleuth/PropertyList/PlistDictionary.cs (revision 71) @@ -74,7 +74,11 @@ keys.Add(key); } - dict.Add(key, value); + if (dict.ContainsKey (key)) { + Console.WriteLine ("Warning: ignoring duplicate key: {0} (null? {1} empty? {2})", key, key == null, key == ""); + } else { + dict.Add(key, value); + } } public bool Remove(string key) Index: data/ipod-model-table =================================================================== --- data/ipod-model-table (revision 69) +++ data/ipod-model-table (revision 71) @@ -117,13 +117,13 @@ Nano 3 Black 8 A261 None YXX Nano 4 Silver 4 B480 None 1P1 -;;Nano 4 Blue 4 B??? None Unknown +Nano 4 Blue 4 B651 None Unknown Nano 4 Pink 4 B654 None 37H Nano 4 Purple 4 B657 None 37K Nano 4 Orange 4 B660 None 37L Nano 4 Green 4 B663 None 37P Nano 4 Yellow 4 B666 None 37Q -Nano 4 Silver 8 B598 None Unknown +Nano 4 Silver 8 B598 None 2ME Nano 4 Blue 8 B732 None 3QS Nano 4 Pink 8 B735 None 3QT Nano 4 Purple 8 B739 None 3QU @@ -133,15 +133,16 @@ Nano 4 Red 8 B751 ProductRed 3QZ Nano 4 Black 8 B754 None 3R0 -Nano 4 Silver 16 B903 None Unknown -Nano 4 Blue 16 B905 None Unknown -Nano 4 Pink 16 B907 None Unknown -Nano 4 Purple 16 B909 None Unknown -Nano 4 Orange 16 B911 None Unknown -Nano 4 Green 16 B913 None Unknown -Nano 4 Yellow 16 B915 None Unknown +;; 5B7, 5B9, 5BC, and 5BD are extrapolations/guesses +Nano 4 Silver 16 B903 None 5B7 +Nano 4 Blue 16 B905 None 5B8 +Nano 4 Pink 16 B907 None 5B9 +Nano 4 Purple 16 B909 None 5BA +Nano 4 Orange 16 B911 None 5BB +Nano 4 Green 16 B913 None 5BC +Nano 4 Yellow 16 B915 None 5BD Nano 4 Red 16 B917 ProductRed 5BE -Nano 4 Black 16 B918 None Unknown +Nano 4 Black 16 B918 None 5BF ;; iPod Video ----------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org