fix PolicyKit patch

This commit is contained in:
Lukas Tinkl 2009-01-07 14:31:59 +00:00
parent 154eb2fa33
commit 7ff99d212a
2 changed files with 9 additions and 29 deletions

View File

@ -1,6 +1,7 @@
diff -ur kdelibs-4.1.3/solid/solid/backends/hal/halstorageaccess.cpp kdelibs-4.1.3-policykit-workaround/solid/solid/backends/hal/halstorageaccess.cpp
--- kdelibs-4.1.3/solid/solid/backends/hal/halstorageaccess.cpp 2008-10-30 14:24:05.000000000 +0100
+++ kdelibs-4.1.3-policykit-workaround/solid/solid/backends/hal/halstorageaccess.cpp 2008-12-08 02:31:43.000000000 +0100
Pouze v kdelibs-4.1.4: kdelibs-4.1.3-policykit-workaround.patch
diff -ur kdelibs-orig/solid/solid/backends/hal/halstorageaccess.cpp kdelibs-4.1.4/solid/solid/backends/hal/halstorageaccess.cpp
--- kdelibs-orig/solid/solid/backends/hal/halstorageaccess.cpp 2009-01-07 00:34:55.000000000 +0100
+++ kdelibs-4.1.4/solid/solid/backends/hal/halstorageaccess.cpp 2009-01-07 15:26:27.000000000 +0100
@@ -17,10 +17,13 @@
*/
@ -37,28 +38,7 @@ diff -ur kdelibs-4.1.3/solid/solid/backends/hal/halstorageaccess.cpp kdelibs-4.1
m_teardownInProgress = false;
emit teardownDone(Solid::UnauthorizedOperation,
error.name()+": "+error.message(),
@@ -235,17 +248,18 @@
"Mount");
QStringList options;
QStringList halOptions = m_device->property("volume.mount.valid_options").toStringList();
+ QString fstype=m_device->property("volume.fstype").toString();
#ifdef Q_OS_FREEBSD
QString uid="-u=";
#else
QString uid="uid=";
#endif
- if (halOptions.contains(uid)) {
+ if (halOptions.contains(uid)
+ && (fstype == "vfat" || fstype == "iso9660" || fstype == "hfs" || fstype == "udf")) {
options << uid+QString::number(::getuid());
}
- QString fstype=m_device->property("volume.fstype").toString();
#ifdef Q_OS_FREEBSD
char *cType;
if ( fstype=="vfat" && halOptions.contains("-L=")) {
@@ -297,6 +311,59 @@
@@ -314,6 +327,59 @@
SLOT(slotDBusError(const QDBusError &)));
}
@ -118,9 +98,9 @@ diff -ur kdelibs-4.1.3/solid/solid/backends/hal/halstorageaccess.cpp kdelibs-4.1
bool Solid::Backends::Hal::StorageAccess::callSystemMount()
{
const QString device = m_device->property("block.device").toString();
diff -ur kdelibs-4.1.3/solid/solid/backends/hal/halstorageaccess.h kdelibs-4.1.3-policykit-workaround/solid/solid/backends/hal/halstorageaccess.h
--- kdelibs-4.1.3/solid/solid/backends/hal/halstorageaccess.h 2008-05-21 13:07:38.000000000 +0200
+++ kdelibs-4.1.3-policykit-workaround/solid/solid/backends/hal/halstorageaccess.h 2008-12-08 02:05:21.000000000 +0100
diff -ur kdelibs-orig/solid/solid/backends/hal/halstorageaccess.h kdelibs-4.1.4/solid/solid/backends/hal/halstorageaccess.h
--- kdelibs-orig/solid/solid/backends/hal/halstorageaccess.h 2009-01-07 00:34:55.000000000 +0100
+++ kdelibs-4.1.4/solid/solid/backends/hal/halstorageaccess.h 2009-01-07 15:26:27.000000000 +0100
@@ -69,6 +69,9 @@
bool callSystemMount();
bool callSystemUnmount();

View File

@ -69,7 +69,7 @@ Patch9: kdelibs-4.0.2-branding.patch
# are loaded from kde4rc
Patch10: kdelibs-4.0.2-no-cache-kdeglobals-paths.patch
# workarounds for policykit and NTFS
Patch11: kdelibs-4.1.3-policykit-workaround.patch
Patch11: kdelibs-4.1.4-policykit-workaround.patch
Patch12: kdelibs-4.1.0-xdg-menu.patch
# patch KStandardDirs to use %{_libexecdir}/kde4 instead of %{_libdir}/kde4/libexec
Patch14: kdelibs-4.0.85-libexecdir.patch