diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2013-08-08 14:55:18 -0500 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2013-08-08 14:55:18 -0500 |
commit | 4bd0fd248f15db483f28083899f8bdde5e79ca29 (patch) | |
tree | 236773d5d54704fef49cfbc359356b866197bc08 | |
parent | 960cc8392da291eaf6c90d2101b721f6c20488f3 (diff) | |
download | tdebase-4bd0fd248f15db483f28083899f8bdde5e79ca29.tar.gz tdebase-4bd0fd248f15db483f28083899f8bdde5e79ca29.zip |
Disable session management in tdeio slaves
This relates to Bug 760
-rw-r--r-- | tdeioslave/home/tdeio_home.cpp | 2 | ||||
-rw-r--r-- | tdeioslave/media/mediamanager/tdehardwarebackend.cpp | 13 | ||||
-rw-r--r-- | tdeioslave/media/tdeio_media.cpp | 2 | ||||
-rw-r--r-- | tdeioslave/remote/tdeio_remote.cpp | 2 | ||||
-rw-r--r-- | tdeioslave/system/tdeio_system.cpp | 2 | ||||
-rw-r--r-- | tdeioslave/thumbnail/thumbnail.cpp | 7 | ||||
-rw-r--r-- | tdeioslave/trash/tdeio_trash.cpp | 3 |
7 files changed, 18 insertions, 13 deletions
diff --git a/tdeioslave/home/tdeio_home.cpp b/tdeioslave/home/tdeio_home.cpp index 109252f43..c4db91128 100644 --- a/tdeioslave/home/tdeio_home.cpp +++ b/tdeioslave/home/tdeio_home.cpp @@ -44,7 +44,7 @@ extern "C" { putenv(strdup("SESSION_MANAGER=")); TDECmdLineArgs::init(argc, argv, "tdeio_home", 0, 0, 0, 0); TDECmdLineArgs::addCmdLineOptions( options ); - TDEApplication app( false, false ); + TDEApplication app( false, false, false ); // We want to be anonymous even if we use DCOP app.dcopClient()->attach(); diff --git a/tdeioslave/media/mediamanager/tdehardwarebackend.cpp b/tdeioslave/media/mediamanager/tdehardwarebackend.cpp index 369f87c3a..0753d2ff2 100644 --- a/tdeioslave/media/mediamanager/tdehardwarebackend.cpp +++ b/tdeioslave/media/mediamanager/tdehardwarebackend.cpp @@ -91,6 +91,7 @@ TDEBackend::~TDEBackend() } void TDEBackend::AddDeviceHandler(TDEGenericDevice *device) { +printf("[RAJA DEBUG 100.0] In TDEBackend::AddDeviceHandler for '%s'\n\r", device->uniqueID().ascii()); fflush(stdout); if (device->type() == TDEGenericDeviceType::Disk) { TDEStorageDevice* sdevice = static_cast<TDEStorageDevice*>(device); AddDevice(sdevice); @@ -98,6 +99,7 @@ void TDEBackend::AddDeviceHandler(TDEGenericDevice *device) { } void TDEBackend::RemoveDeviceHandler(TDEGenericDevice *device) { +printf("[RAJA DEBUG 100.0] In TDEBackend::RemoveDeviceHandler for '%s'\n\r", device->uniqueID().ascii()); fflush(stdout); if (device->type() == TDEGenericDeviceType::Disk) { TDEStorageDevice* sdevice = static_cast<TDEStorageDevice*>(device); RemoveDevice(sdevice); @@ -105,6 +107,7 @@ void TDEBackend::RemoveDeviceHandler(TDEGenericDevice *device) { } void TDEBackend::ModifyDeviceHandler(TDEGenericDevice *device) { +printf("[RAJA DEBUG 100.0] In TDEBackend::ModifyDeviceHandler for '%s'\n\r", device->uniqueID().ascii()); fflush(stdout); if (device->type() == TDEGenericDeviceType::Disk) { TDEStorageDevice* sdevice = static_cast<TDEStorageDevice*>(device); ModifyDevice(sdevice); @@ -1198,10 +1201,12 @@ TQString TDEBackend::unmount(const TQString &_udi) // There is a possibility that the storage device was unceremoniously removed from the system immediately after it was unmounted // There is no reliable way to know if this happened either! // For now, see if the device node still exists - TQFileInfo checkDN(node); - if (!checkDN.exists()) { - m_mediaList.removeMedium(uid, true); - } +// RAJA FIXME +// Is this causing/masking the Eject/Unmount race condition? +// TQFileInfo checkDN(node); +// if (!checkDN.exists()) { +// m_mediaList.removeMedium(uid, true); +// } return TQString(); } diff --git a/tdeioslave/media/tdeio_media.cpp b/tdeioslave/media/tdeio_media.cpp index 9ed37e82f..9124568c1 100644 --- a/tdeioslave/media/tdeio_media.cpp +++ b/tdeioslave/media/tdeio_media.cpp @@ -46,7 +46,7 @@ extern "C" { putenv(strdup("SESSION_MANAGER=")); TDECmdLineArgs::init(argc, argv, "tdeio_media", 0, 0, 0, 0); TDECmdLineArgs::addCmdLineOptions( options ); - TDEApplication app( false, false ); + TDEApplication app( false, false, false ); // We want to be anonymous even if we use DCOP app.dcopClient()->attach(); diff --git a/tdeioslave/remote/tdeio_remote.cpp b/tdeioslave/remote/tdeio_remote.cpp index b5350b7e2..271b0913f 100644 --- a/tdeioslave/remote/tdeio_remote.cpp +++ b/tdeioslave/remote/tdeio_remote.cpp @@ -44,7 +44,7 @@ extern "C" { putenv(strdup("SESSION_MANAGER=")); TDECmdLineArgs::init(argc, argv, "tdeio_remote", 0, 0, 0, 0); TDECmdLineArgs::addCmdLineOptions( options ); - TDEApplication app( false, false ); + TDEApplication app( false, false, false ); // We want to be anonymous even if we use DCOP app.dcopClient()->attach(); diff --git a/tdeioslave/system/tdeio_system.cpp b/tdeioslave/system/tdeio_system.cpp index d904eda0d..54dd0da6d 100644 --- a/tdeioslave/system/tdeio_system.cpp +++ b/tdeioslave/system/tdeio_system.cpp @@ -45,7 +45,7 @@ extern "C" { putenv(strdup("SESSION_MANAGER=")); TDECmdLineArgs::init(argc, argv, "tdeio_system", 0, 0, 0, 0); TDECmdLineArgs::addCmdLineOptions( options ); - TDEApplication app( false, false ); + TDEApplication app( false, false, false ); // We want to be anonymous even if we use DCOP app.dcopClient()->attach(); diff --git a/tdeioslave/thumbnail/thumbnail.cpp b/tdeioslave/thumbnail/thumbnail.cpp index e5c67ec0d..0e6b24880 100644 --- a/tdeioslave/thumbnail/thumbnail.cpp +++ b/tdeioslave/thumbnail/thumbnail.cpp @@ -98,16 +98,17 @@ int kdemain(int argc, char **argv) #ifdef USE_KINSTANCE TDEInstance instance("tdeio_thumbnail"); #else - // creating TDEApplication in a slave in not a very good idea, + // creating TDEApplication in a slave is not a very good idea, // as dispatchLoop() doesn't allow it to process its messages, // so it for example wouldn't reply to ksmserver - on the other // hand, this slave uses QPixmaps for some reason, and they // need QApplication // and HTML previews need even TDEApplication :( - putenv(strdup("SESSION_MANAGER=")); + // session management is therefore forcibly disabled on creation + // to prevent session management hangs and stalls TDEApplication::disableAutoDcopRegistration(); - TDEApplication app(argc, argv, "tdeio_thumbnail", false, true); + TDEApplication app(argc, argv, "tdeio_thumbnail", false, true, false); #endif if (argc != 4) diff --git a/tdeioslave/trash/tdeio_trash.cpp b/tdeioslave/trash/tdeio_trash.cpp index 02cda02dd..e8fdec8f5 100644 --- a/tdeioslave/trash/tdeio_trash.cpp +++ b/tdeioslave/trash/tdeio_trash.cpp @@ -54,11 +54,10 @@ extern "C" { { //TDEInstance instance( "tdeio_trash" ); // TDEApplication is necessary to use tdeio_file - putenv(strdup("SESSION_MANAGER=")); TDEApplication::disableAutoDcopRegistration(); TDECmdLineArgs::init(argc, argv, "tdeio_trash", 0, 0, 0, 0); TDECmdLineArgs::addCmdLineOptions( options ); - TDEApplication app( false, false ); + TDEApplication app( false, false, false ); TDECmdLineArgs *args = TDECmdLineArgs::parsedArgs(); TrashProtocol slave( args->arg(0), args->arg(1), args->arg(2) ); |