- Update to version 1.14.0.
OBS-URL: https://build.opensuse.org/package/show/X11:MATE:Factory/mate-system-monitor?expand=0&rev=21
This commit is contained in:
committed by
Git OBS Bridge
parent
a494d840f5
commit
ee76da53af
@@ -1,49 +1,24 @@
|
||||
--- a/src/procman_gksu.cpp
|
||||
+++ b/src/procman_gksu.cpp
|
||||
@@ -28,18 +28,20 @@ static void load_gksu(void)
|
||||
gboolean procman_gksu_create_root_password_dialog(const char *command)
|
||||
{
|
||||
GError *e = NULL;
|
||||
+ gchar *cmd;
|
||||
@@ -10,18 +10,18 @@ procman_gksu_create_root_password_dialog
|
||||
gboolean success;
|
||||
GError *error = NULL;
|
||||
|
||||
- /* Returns FALSE or TRUE on success, depends on version ... */
|
||||
- gksu_run(command, &e);
|
||||
+ cmd = g_strdup_printf("xdg-su -c '%s'", command);
|
||||
+ g_spawn_command_line_sync(cmd, NULL, NULL, NULL, &e);
|
||||
+ g_free(cmd);
|
||||
- command_line = g_strdup_printf ("gksu '%s'", command);
|
||||
+ command_line = g_strdup_printf ("xdg-su -c '%s'", command);
|
||||
success = g_spawn_command_line_sync (command_line, NULL, NULL, NULL, &error);
|
||||
g_free (command_line);
|
||||
|
||||
if (e) {
|
||||
- g_critical("Could not run gksu_run(\"%s\") : %s\n",
|
||||
+ g_critical("Could not run xdg-su -c '%s') : %s\n",
|
||||
command, e->message);
|
||||
g_error_free(e);
|
||||
if (!success) {
|
||||
- g_critical ("Could not run gksu '%s' : %s\n",
|
||||
+ g_critical ("Could not run xdg-su -c '%s') : %s\n",
|
||||
command, error->message);
|
||||
g_error_free (error);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
- g_message("gksu_run did fine\n");
|
||||
+ g_message("xdg-su did fine\n");
|
||||
- g_debug ("gksu did fine\n");
|
||||
+ g_debug ("xdg-su did fine\n");
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@@ -48,7 +50,6 @@ gboolean procman_gksu_create_root_passwo
|
||||
gboolean
|
||||
procman_has_gksu(void)
|
||||
{
|
||||
- load_gksu();
|
||||
- return gksu_run != NULL;
|
||||
+ return g_file_test("/usr/bin/gksu", G_FILE_TEST_EXISTS);
|
||||
}
|
||||
|
||||
--- a/src/procman_matesu.cpp
|
||||
+++ b/src/procman_matesu.cpp
|
||||
@@ -19,8 +19,8 @@ load_matesu(void)
|
||||
|
||||
init = TRUE;
|
||||
|
||||
- load_symbols("libmatesu.so.0",
|
||||
- "matesu_exec", &matesu_exec,
|
||||
+ load_symbols("libgnomesu.so.0",
|
||||
+ "gnomesu_exec", &matesu_exec,
|
||||
NULL);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user