Bug 482463 - Amarok crashes when attempting to open audio CD from drop-down choices in Devices applet
Summary: Amarok crashes when attempting to open audio CD from drop-down choices in Dev...
Status: RESOLVED FIXED
Alias: None
Product: amarok
Classification: Applications
Component: general (show other bugs)
Version: 2.9.71
Platform: openSUSE Linux
: NOR crash
Target Milestone: kf5
Assignee: Amarok Developers
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2024-03-05 12:49 UTC by John Carrick Smith
Modified: 2024-03-29 23:47 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Carrick Smith 2024-03-05 12:49:10 UTC
Application: amarok (2.9.71)

Qt Version: 5.15.8
Frameworks Version: 5.103.0
Operating System: Linux 5.14.21-150500.55.49-default x86_64
Windowing System: X11
Distribution: "openSUSE Leap 15.5"
DrKonqi: 5.27.9 [KCrashBackend]

-- Information about the crash:
Firstly Amarok found 0 tracks on an audio CD when it appeared in Media Sources.
Closed Amarok.
Atttempted to play CD by selecting "Play audio CD with Amarok" and this crash occured.
Tried VLC which worked.

The crash can be reproduced every time.

-- Backtrace:
Application: Amarok (amarok), signal: Segmentation fault

[KCrash Handler]
#4  0x00007f210bae73bb in MainWindow::playAudioCd (this=0x0) at /usr/src/debug/amarok-2.9.75git.20221114T020258~457db492b4-bp155.1.12.x86_64/src/MainWindow.cpp:1366
#5  0x00007f210bad1f6a in App::handleCliArgs (this=this@entry=0x7ffda57a8fe0, cwd=...) at /usr/src/debug/amarok-2.9.75git.20221114T020258~457db492b4-bp155.1.12.x86_64/src/App.cpp:303
#6  0x00007f210bad2293 in App::newInstance (this=0x7ffda57a8fe0) at /usr/src/debug/amarok-2.9.75git.20221114T020258~457db492b4-bp155.1.12.x86_64/src/App.cpp:632
#7  0x00007f210bad26b4 in App::continueInit (this=this@entry=0x7ffda57a8fe0) at /usr/src/debug/amarok-2.9.75git.20221114T020258~457db492b4-bp155.1.12.x86_64/src/App.cpp:444
#8  0x00005590594c804a in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/amarok-2.9.75git.20221114T020258~457db492b4-bp155.1.12.x86_64/src/main.cpp:394
[Inferior 1 (process 4969) detached]

Reported using DrKonqi
Comment 1 Bug Janitor Service 2024-03-29 22:59:22 UTC
A possibly relevant merge request was started @ https://invent.kde.org/multimedia/amarok/-/merge_requests/74
Comment 2 Tuomas Nurmi 2024-03-29 23:44:26 UTC
Git commit 212b693c210f673e9dac91d4c62995e30ad5ecbd by Tuomas Nurmi.
Committed on 29/03/2024 at 23:36.
Pushed by nurmi into branch 'master'.

Fix --cdplay command line option

First, avoid touching MainWindow member variables before MainWindow is
constructed to avoid immediate segfault.

Second, don't try casting cd collection to MemoryCollection, which it doesn't
inherit (at least anymore). Casting to MediaDeviceCollection actually works.
Hard to tell since when this has been broken, but most of relevant code seems
to be last changed in 2010 or earlier, so possibly a while.
Related: bug 279188

M  +2    -2    ChangeLog
M  +8    -4    src/MainWindow.cpp

https://invent.kde.org/multimedia/amarok/-/commit/212b693c210f673e9dac91d4c62995e30ad5ecbd
Comment 3 Tuomas Nurmi 2024-03-29 23:47:27 UTC
Thank you for your report!
Fix for "Amarok found 0 tracks on an audio CD when it appeared in Media Sources" was merged in a couple of days ago, and fix for crash occurring with "Play audio CD with Amarok" just a moment ago. (They will be included in the upcoming 2.9.76 release)