rev 4772 - trunk/packages/kdebase/debian/patches
Modestas Vainius
modax-guest at costa.debian.org
Mon Oct 23 12:07:41 UTC 2006
Author: modax-guest
Date: 2006-10-23 12:07:41 +0000 (Mon, 23 Oct 2006)
New Revision: 4772
Modified:
trunk/packages/kdebase/debian/patches/29_halbackend_fstab_improvements.diff
trunk/packages/kdebase/debian/patches/33_mounthelper_find_medium_by_url.diff
Log:
Indentation corrections for my patches. Follow indentation style of the source files (spaces vs tabs)
Modified: trunk/packages/kdebase/debian/patches/29_halbackend_fstab_improvements.diff
===================================================================
--- trunk/packages/kdebase/debian/patches/29_halbackend_fstab_improvements.diff 2006-10-23 06:35:50 UTC (rev 4771)
+++ trunk/packages/kdebase/debian/patches/29_halbackend_fstab_improvements.diff 2006-10-23 12:07:41 UTC (rev 4772)
@@ -228,19 +228,19 @@
DBusConnection *dbus_connection;
- QMap<KIO::Job *, QString> mount_jobs;
-+ /**
-+ * Data structure for fstab mount/unmount jobs
-+ */
-+ struct mount_job_data {
-+ // [in] Medium, which is being mounted/unmounted by the job
-+ const Medium* medium;
-+ // [in,out] Should be set to true when the job completes
-+ bool completed;
-+ // [out] KIO::Error if an error occured during operation. Otherwise, 0
-+ int error;
-+ // [out] Error message to be displayed to the user
-+ QString errorMessage;
-+ };
++ /**
++ * Data structure for fstab mount/unmount jobs
++ */
++ struct mount_job_data {
++ // [in] Medium, which is being mounted/unmounted by the job
++ const Medium* medium;
++ // [in,out] Should be set to true when the job completes
++ bool completed;
++ // [out] KIO::Error if an error occured during operation. Otherwise, 0
++ int error;
++ // [out] Error message to be displayed to the user
++ QString errorMessage;
++ };
+
+ QMap<KIO::Job *, struct mount_job_data*> mount_jobs;
};
@@ -252,22 +252,22 @@
}
else if (args->isSet("s") || args->isSet("e"))
{
-+ /*
-+ * We want to call mediamanager unmount before invoking eject. That's
-+ * because unmount would provide an informative error message in case of
-+ * failure. However, there are cases when unmount would fail
-+ * (supermount, slackware, see bug#116209) but eject would succeed.
-+ * Thus if unmount fails, save unmount error message and invokeEject()
-+ * anyway. Only if both unmount and eject fail, notify the user by
-+ * displaying the saved error message (see ejectFinished()).
-+ */
++ /*
++ * We want to call mediamanager unmount before invoking eject. That's
++ * because unmount would provide an informative error message in case of
++ * failure. However, there are cases when unmount would fail
++ * (supermount, slackware, see bug#116209) but eject would succeed.
++ * Thus if unmount fails, save unmount error message and invokeEject()
++ * anyway. Only if both unmount and eject fail, notify the user by
++ * displaying the saved error message (see ejectFinished()).
++ */
+ if (medium.isMounted())
+ {
-+ DCOPRef mediamanager("kded", "mediamanager");
-+ DCOPReply reply = mediamanager.call( "unmount", medium.id());
-+ if (reply.isValid())
-+ reply.get(m_errorStr);
-+ m_device = device;
++ DCOPRef mediamanager("kded", "mediamanager");
++ DCOPReply reply = mediamanager.call( "unmount", medium.id());
++ if (reply.isValid())
++ reply.get(m_errorStr);
++ m_device = device;
+ }
invokeEject(device, true);
}
@@ -304,7 +304,7 @@
- {
- invokeEject(m_device, true);
- }
-+ this, SLOT( ejectFinished(KProcess *) ) );
++ this, SLOT( ejectFinished(KProcess *) ) );
+ proc->start();
}
@@ -332,20 +332,20 @@
- {
- QTimer::singleShot(0, this, SLOT(finished()) );
- }
-+ /*
-+ * If eject failed, report the error stored in m_errorStr
-+ */
-+ if (proc->normalExit() && proc->exitStatus() == 0) {
-+ ::exit(0);
-+ } else {
-+ if (m_errorStr.isEmpty()) {
-+ if (m_isCdrom)
-+ m_errorStr = i18n("The device was successfully unmounted, but the tray could not be opened");
-+ else
-+ m_errorStr = i18n("The device was successfully unmounted, but could not be ejected");
-+ }
-+ QTimer::singleShot(0, this, SLOT(error()));
-+ }
++ /*
++ * If eject failed, report the error stored in m_errorStr
++ */
++ if (proc->normalExit() && proc->exitStatus() == 0) {
++ ::exit(0);
++ } else {
++ if (m_errorStr.isEmpty()) {
++ if (m_isCdrom)
++ m_errorStr = i18n("The device was successfully unmounted, but the tray could not be opened");
++ else
++ m_errorStr = i18n("The device was successfully unmounted, but could not be ejected");
++ }
++ QTimer::singleShot(0, this, SLOT(error()));
++ }
}
void MountHelper::error()
Modified: trunk/packages/kdebase/debian/patches/33_mounthelper_find_medium_by_url.diff
===================================================================
--- trunk/packages/kdebase/debian/patches/33_mounthelper_find_medium_by_url.diff 2006-10-23 06:35:50 UTC (rev 4771)
+++ trunk/packages/kdebase/debian/patches/33_mounthelper_find_medium_by_url.diff 2006-10-23 12:07:41 UTC (rev 4772)
@@ -1,5 +1,5 @@
---- kdebase-3.5.5a.dfsg.1/kioslave/media/mounthelper/kio_media_mounthelper.cpp 2006-10-23 02:26:27.000000000 +0300
-+++ kdebase-3.5.5a.dfsg.1/kioslave/media/mounthelper/kio_media_mounthelper.cpp 2006-10-23 03:24:12.000000000 +0300
+--- kdebase-3.5.5a.dfsg.1/kioslave/media/mounthelper/kio_media_mounthelper.cpp 2006-10-23 03:24:12.000000000 +0300
++++ kdebase-3.5.5a.dfsg.1/kioslave/media/mounthelper/kio_media_mounthelper.cpp 2006-10-23 13:30:46.000000000 +0300
@@ -35,17 +35,28 @@
#include "kio_media_mounthelper.h"
@@ -25,12 +25,13 @@
+ if ( !reply.isValid() ) {
+ m_errorStr = i18n("Internal Error");
+ return Medium(QString::null, QString::null);
++ }
++ return Medium::create(reply);
++ } else {
++ return medium;
}
-
- return Medium::create(reply);
-+ } else {
-+ return medium;
-+ }
+- return Medium::create(reply);
}
MountHelper::MountHelper() : KApplication()
More information about the pkg-kde-commits
mailing list