From kde-commits Sun Aug 12 13:30:17 2007 From: =?utf-8?q?Richard=20L=C3=A4rk=C3=A4ng?= Date: Sun, 12 Aug 2007 13:30:17 +0000 To: kde-commits Subject: KDE/kdemultimedia/kioslave/audiocd Message-Id: <1186925417.297180.8483.nullmailer () svn ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=118692542432531 SVN commit 699259 by larkang: Initialize discid, and don't crash if cddb lookup failed M +6 -2 audiocd.cpp --- trunk/KDE/kdemultimedia/kioslave/audiocd/audiocd.cpp #699258:699259 @@ -103,6 +103,7 @@ clearURLargs(); s_info = i18n("Information"); s_fullCD = i18n("Full CD"); + discid = 0; } void clearURLargs() { @@ -257,8 +258,11 @@ KCDDB::Client c; d->cddbResult = c.lookup(d->cd.discSignature()); - d->cddbList = c.lookupResponse(); - d->cddbBestChoice = d->cddbList.first(); + if (d->cddbResult == Success) + { + d->cddbList = c.lookupResponse(); + d->cddbBestChoice = d->cddbList.first(); + } generateTemplateTitles(); }