[prev in list] [next in list] [prev in thread] [next in thread] 

List:       amarok-bugs-dist
Subject:    [amarok] [Bug 339190] amarok falls into endless loop if certain audioCDs are inserted [@ Dynamic::Tr
From:       <clubmajo () yahoo ! es>
Date:       2015-07-26 0:45:17
Message-ID: bug-339190-71684-qJyGeEy6au () http ! bugs ! kde ! org/
[Download RAW message or body]

https://bugs.kde.org/show_bug.cgi?id=339190

clubmajo@yahoo.es changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |clubmajo@yahoo.es

--- Comment #21 from clubmajo@yahoo.es ---
I traced the bug and I found that the loop where it got stuck is
AudioCdCollection.cpp:467

Amarok generates a new path for the next track but that track is invalid. It
generates something like "audiocd:/Track XX.wav" when the correct form would be
"audiocd:/Track XX.wav?device=/dev/srX".

I didn't debugged kio_audiocd but I think that it calls AudioCDProtocol::stat
which will call AudioCDProtocol::initRequest and this one will call
AudioCDProtocol::parseURLArgs.

AudioCDProtocol::parseURLArgs will see that url hasn't a query part so will
leave d->device = NULL and AudioCDProtocol::initRequest will return NULL

AudoCDProtocol::stat will start checking if client is requesting root folder
that represents the list of different avaiable cd drives. It will check it
using:

struct cdrom_drive * drive = initRequest(url);
if (!drive && d->device.isEmpty()) {
   // This is top level directory with CDROM devices
   ...

As drive is NULL and device is NULL because parseURLArgs didn't set it, it will
believe that you're trying stat the root of "audiocd:/" and will return always
a valid stat even if the path doesn't exist

I saw that there is a more recent implementation of AudioCDCollection but it's
in another branch yet

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Amarok-bugs-dist mailing list
Amarok-bugs-dist@kde.org
https://mail.kde.org/mailman/listinfo/amarok-bugs-dist

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic