[Kde-hardware-devel] Not receiving Solid::DeviceNotifier deviceRemoved() SIGNAL
Christian Esken
esken at kde.org
Thu Jun 16 21:06:55 CEST 2011
Hello,
I am using Solid in KMix for Hotplug events. I receive the deviceAdded()
signal, but not the deviceRemoved() signal.
This has really nasty impacts on KMix when repeatedly unplugging and
hotplugging. For example soundcard devices show up multiple times in KMix, and
it messes up internal reference counts and ultimately KMix crashes sooner or
later.
The code looks like this:
void KMixDeviceManager::initHotplug()
{
connect (Solid::DeviceNotifier::instance(), SIGNAL(deviceAdded(const
QString&)), SLOT(pluggedSlot(const QString&)) );
connect (Solid::DeviceNotifier::instance(), SIGNAL(deviceRemoved(const
QString&)), SLOT(unpluggedSlot(const QString&)) );
}
Full code in
http://websvn.kde.org/trunk/KDE/kdemultimedia/kmix/core/kmixdevicemanager.cpp?revision=1180839&view=markup
Any help is greatly appreciated.
Greetings,
Christian
More information about the Kde-hardware-devel
mailing list