Files
haikuports/kde-base/kwrite/patches/kwrite-20.12.0.patchset
Gerasim Troeglazov f5b2a7d016 KWrite: bump version
2020-12-16 09:53:23 +10:00

23 lines
637 B
Plaintext

From 62c9e1bc35523be31a3f089fae605fdee3283fa1 Mon Sep 17 00:00:00 2001
From: Gerasim Troeglazov <3dEyes@gmail.com>
Date: Sun, 24 Mar 2019 20:35:16 +1000
Subject: Allow running as root on Haiku
diff --git a/kwrite/main.cpp b/kwrite/main.cpp
index e972a9b..84a197b 100644
--- a/kwrite/main.cpp
+++ b/kwrite/main.cpp
@@ -50,7 +50,7 @@
extern "C" Q_DECL_EXPORT int main(int argc, char **argv)
{
-#ifndef Q_OS_WIN
+#if !defined(Q_OS_WIN) && !defined(Q_OS_HAIKU)
// Prohibit using sudo or kdesu (but allow using the root user directly)
if (getuid() == 0) {
if (!qEnvironmentVariableIsEmpty("SUDO_USER")) {
--
2.19.1