Files
main/desktop/kde/applications/kate/files/kate-17.04.0-allow-root.patch
T
2018-03-23 04:21:54 +03:00

29 lines
612 B
Diff
Executable File

--- a/kate/main.cpp
+++ b/kate/main.cpp
@@ -51,24 +51,9 @@
#include "qtsingleapplication/qtsingleapplication.h"
#endif
-#ifndef Q_OS_WIN
-#include <unistd.h>
-#endif
-#include <iostream>
-
int main(int argc, char **argv)
{
-#ifndef Q_OS_WIN
- /**
- * Check whether we are running as root
- **/
- if (getuid() == 0) {
- std::cout << "Executing Kate as root is not possible. To edit files as root use:" << std::endl;
- std::cout << "SUDO_EDITOR=kate sudoedit <file>" << std::endl;
- return 0;
- }
-#endif
/**
* init resources from our static lib
*/