This commit is contained in:
parent
6052cc80ae
commit
6ff5030415
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:66199687271c892551e7ecbbd2318e69539d9b61664f2dd764e7fce72133e8d1
|
||||
size 783944
|
3
gnome-session-2.23.91.tar.bz2
Normal file
3
gnome-session-2.23.91.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:8009adf3d43e78693e87199a78462aa0d3929fdb9806cc36346a417636d730e0
|
||||
size 788716
|
@ -1,110 +0,0 @@
|
||||
Index: tools/gnome-session-save.c
|
||||
===================================================================
|
||||
--- tools/gnome-session-save.c (révision 5026)
|
||||
+++ tools/gnome-session-save.c (copie de travail)
|
||||
@@ -38,7 +38,10 @@
|
||||
#define GSM_INTERFACE_DBUS "org.gnome.SessionManager"
|
||||
|
||||
/* True if killing. */
|
||||
-static gboolean do_logout = FALSE;
|
||||
+static gboolean kill = FALSE;
|
||||
+
|
||||
+static gboolean logout_dialog = FALSE;
|
||||
+static gboolean shutdown_dialog = FALSE;
|
||||
|
||||
/* True if we should use dialog boxes */
|
||||
static gboolean gui = FALSE;
|
||||
@@ -50,7 +53,9 @@ static char *session_name = NULL;
|
||||
|
||||
static GOptionEntry options[] = {
|
||||
{"session-name", 's', 0, G_OPTION_ARG_STRING, &session_name, N_("Set the current session name"), N_("NAME")},
|
||||
- {"kill", '\0', 0, G_OPTION_ARG_NONE, &do_logout, N_("Kill session"), NULL},
|
||||
+ {"logout-dialog", '\0', 0, G_OPTION_ARG_NONE, &logout_dialog, N_("Show logout dialog"), NULL},
|
||||
+ {"shutdown-dialog", '\0', 0, G_OPTION_ARG_NONE, &shutdown_dialog, N_("Show shutdown dialog"), NULL},
|
||||
+ {"kill", '\0', 0, G_OPTION_ARG_NONE, &kill, N_("Kill session"), NULL},
|
||||
{"gui", '\0', 0, G_OPTION_ARG_NONE, &gui, N_("Use dialog boxes for errors"), NULL},
|
||||
{"silent", '\0', 0, G_OPTION_ARG_NONE, &silent, N_("Do not require confirmation"), NULL},
|
||||
{NULL}
|
||||
@@ -208,10 +213,58 @@ logout_session (gboolean show_confirmati
|
||||
}
|
||||
}
|
||||
|
||||
+static void
|
||||
+do_shutdown_dialog (void)
|
||||
+{
|
||||
+ DBusGConnection *bus;
|
||||
+ DBusGProxy *sm_proxy;
|
||||
+ GError *error;
|
||||
+ gboolean res;
|
||||
+
|
||||
+ sm_proxy = NULL;
|
||||
+
|
||||
+ bus = get_session_bus ();
|
||||
+ if (bus == NULL) {
|
||||
+ display_error (_("Could not connect to the session manager"));
|
||||
+ goto out;
|
||||
+ }
|
||||
+
|
||||
+ sm_proxy = get_sm_proxy (bus);
|
||||
+ if (sm_proxy == NULL) {
|
||||
+ display_error (_("Could not connect to the session manager"));
|
||||
+ goto out;
|
||||
+ }
|
||||
+
|
||||
+ error = NULL;
|
||||
+ res = dbus_g_proxy_call (sm_proxy,
|
||||
+ "Shutdown",
|
||||
+ &error,
|
||||
+ G_TYPE_INVALID,
|
||||
+ G_TYPE_INVALID);
|
||||
+
|
||||
+ if (!res) {
|
||||
+ if (error != NULL) {
|
||||
+ g_warning ("Failed to call shutdown: %s",
|
||||
+ error->message);
|
||||
+ g_error_free (error);
|
||||
+ } else {
|
||||
+ g_warning ("Failed to call shutdown");
|
||||
+ }
|
||||
+
|
||||
+ goto out;
|
||||
+ }
|
||||
+
|
||||
+ out:
|
||||
+ if (sm_proxy != NULL) {
|
||||
+ g_object_unref (sm_proxy);
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
GError *error;
|
||||
+ int conflicting_options;
|
||||
|
||||
/* Initialize the i18n stuff */
|
||||
bindtextdomain (GETTEXT_PACKAGE, LOCALE_DIR);
|
||||
@@ -225,8 +278,22 @@ main (int argc, char *argv[])
|
||||
exit (1);
|
||||
}
|
||||
|
||||
- if (do_logout) {
|
||||
+ conflicting_options = 0;
|
||||
+ if (kill)
|
||||
+ conflicting_options++;
|
||||
+ if (logout_dialog)
|
||||
+ conflicting_options++;
|
||||
+ if (shutdown_dialog)
|
||||
+ conflicting_options++;
|
||||
+ if (conflicting_options > 1)
|
||||
+ display_error (_("Program called with conflicting options"));
|
||||
+
|
||||
+ if (kill) {
|
||||
logout_session (! silent);
|
||||
+ } else if (logout_dialog) {
|
||||
+ logout_session (TRUE);
|
||||
+ } else if (shutdown_dialog) {
|
||||
+ do_shutdown_dialog ();
|
||||
}
|
||||
|
||||
return exit_status;
|
@ -1,70 +0,0 @@
|
||||
Index: gnome-session/main.c
|
||||
===================================================================
|
||||
--- gnome-session/main.c (révision 4982)
|
||||
+++ gnome-session/main.c (copie de travail)
|
||||
@@ -25,6 +25,8 @@
|
||||
#include <signal.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
+#include <unistd.h>
|
||||
+#include <errno.h>
|
||||
|
||||
#include <glib/gi18n.h>
|
||||
#include <glib/goption.h>
|
||||
@@ -390,6 +392,42 @@ signal_cb (int signo,
|
||||
return ret;
|
||||
}
|
||||
|
||||
+static gboolean
|
||||
+require_dbus_session (int argc, char **argv, GError **error)
|
||||
+{
|
||||
+ int i;
|
||||
+ char **new_argv;
|
||||
+
|
||||
+ if (g_getenv ("DBUS_SESSION_BUS_ADDRESS"))
|
||||
+ return TRUE;
|
||||
+
|
||||
+ /* Just a sanity check to prevent infinite recursion if
|
||||
+ * dbus-launch fails to set DBUS_SESSION_BUS_ADDRESS
|
||||
+ */
|
||||
+ g_return_val_if_fail (!g_str_has_prefix (argv[0], "dbus-launch"), TRUE);
|
||||
+
|
||||
+ /* +2 for our new arguments, +1 for NULL */
|
||||
+ new_argv = g_malloc (argc+3 * sizeof (*argv));
|
||||
+
|
||||
+ new_argv[0] = "dbus-launch";
|
||||
+ new_argv[1] = "--exit-with-session";
|
||||
+ new_argv[2] = argv[0];
|
||||
+ for (i = 1; i < argc-1; i++)
|
||||
+ new_argv[i+2] = argv[i];
|
||||
+ new_argv[i+2] = NULL;
|
||||
+
|
||||
+ if (!execvp ("dbus-launch", new_argv)) {
|
||||
+ g_set_error (error,
|
||||
+ G_SPAWN_ERROR,
|
||||
+ G_SPAWN_ERROR_FAILED,
|
||||
+ "No session bus and could not exec dbus-launch: %s",
|
||||
+ g_strerror (errno));
|
||||
+ return FALSE;
|
||||
+ }
|
||||
+ /* Should not be reached */
|
||||
+ return TRUE;
|
||||
+}
|
||||
+
|
||||
int
|
||||
main (int argc, char **argv)
|
||||
{
|
||||
@@ -401,6 +439,13 @@ main (int argc, char **argv)
|
||||
GsmXsmpServer *xsmp_server;
|
||||
GdmSignalHandler *signal_handler;
|
||||
|
||||
+ /* Ensure that we have a session bus:
|
||||
+ * http://bugzilla.gnome.org/show_bug.cgi?id=546863
|
||||
+ */
|
||||
+ if (!require_dbus_session (argc, argv, &error)) {
|
||||
+ gsm_util_init_error (TRUE, "%s", error->message);
|
||||
+ }
|
||||
+
|
||||
bindtextdomain (GETTEXT_PACKAGE, LOCALE_DIR);
|
||||
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
|
||||
textdomain (GETTEXT_PACKAGE);
|
@ -1,3 +1,23 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Sep 04 16:25:49 CEST 2008 - mboman@novell.com
|
||||
|
||||
- Update to version 2.23.91:
|
||||
+ Bugs fixed: bgo#548710, bgo#548909, bgo#548980, bgo#548982,
|
||||
bgo#546863, bgo#550211, bgo#542880, bgo#547272
|
||||
+ Honor the list of required apps in the list key instead of loading all
|
||||
component keys in the dir
|
||||
+ Look in app dirs for required components
|
||||
+ Do not use and install gnome-wm by default
|
||||
+ Add command line option to override the gconf key used to look up the
|
||||
default session
|
||||
+ Fix add/edit dialog of the capplet
|
||||
+ Fix leaks
|
||||
+ Code cleanups
|
||||
+ Translation updates
|
||||
- Removed gnome-session-launch-dbus.patch. Fixed upstream.
|
||||
- Removed gnome-session-bgo550211-gnome-session-save-logout.patch.
|
||||
Fixed upstream
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Sep 1 16:25:49 CEST 2008 - vuntz@novell.com
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# spec file for package gnome-session (Version 2.23.90)
|
||||
# spec file for package gnome-session (Version 2.23.91)
|
||||
#
|
||||
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
@ -19,11 +19,15 @@
|
||||
|
||||
|
||||
Name: gnome-session
|
||||
BuildRequires: control-center2-devel fdupes gnome-common gnome-desktop-devel gnome-keyring-devel gnome-patch-translation gnome-settings-daemon-devel hicolor-icon-theme intltool libglade2-devel libgnomekbd libnotify-devel perl-XML-Parser tcpd-devel update-desktop-files
|
||||
BuildRequires: control-center2-devel fdupes gnome-common gnome-desktop-devel
|
||||
BuildRequires: gnome-keyring-devel gnome-patch-translation
|
||||
BuildRequires: gnome-settings-daemon-devel hicolor-icon-theme intltool
|
||||
BuildRequires: libglade2-devel libgnomekbd libnotify-devel perl-XML-Parser
|
||||
BuildRequires: tcpd-devel update-desktop-files
|
||||
License: GPL v2 or later; LGPL v2.1 or later
|
||||
Group: System/GUI/GNOME
|
||||
Version: 2.23.90
|
||||
Release: 8
|
||||
Version: 2.23.91
|
||||
Release: 1
|
||||
Summary: Session Tools for the GNOME 2.x Desktop
|
||||
Url: http://www.gnome.org
|
||||
Source: %{name}-%{version}.tar.bz2
|
||||
@ -51,10 +55,6 @@ Patch3: gnome-session-bgo507101-tile-ui.patch
|
||||
Patch4: gnome-session-gnome-wm-compiz-manager.patch
|
||||
#PATCH-FIX-OPENSUSE gnome-session-bnc389137-splash-layout.patch bnc389137 vuntz@novell.com -- Improve layout with our splash screen.
|
||||
Patch5: gnome-session-bnc389137-splash-layout.patch
|
||||
#PATCH-FIX-UPSTREAM gnome-session-launch-dbus.patch bgo546863 vuntz@novell.com -- Launch dbus if it's not already running
|
||||
Patch6: gnome-session-launch-dbus.patch
|
||||
#PATCH-FIX-UPSTREAM gnome-session-bgo550211-gnome-session-save-logout.patch bgo550211 vuntz@novell.com -- Add --{logout,shutdown}-dialog to gnome-session-save
|
||||
Patch7: gnome-session-bgo550211-gnome-session-save-logout.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
Recommends: control-center2
|
||||
Obsoletes: gnome-core
|
||||
@ -117,8 +117,6 @@ Authors:
|
||||
%patch3 -p0
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
%patch6
|
||||
%patch7 -p0
|
||||
#gnome-patch-translation-update
|
||||
|
||||
%build
|
||||
@ -188,6 +186,23 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%files lang -f %{name}-2.0.lang
|
||||
|
||||
%changelog
|
||||
* Thu Sep 04 2008 mboman@novell.com
|
||||
- Update to version 2.23.91:
|
||||
+ Bugs fixed: bgo#548710, bgo#548909, bgo#548980, bgo#548982,
|
||||
bgo#546863, bgo#550211, bgo#542880, bgo#547272
|
||||
+ Honor the list of required apps in the list key instead of loading all
|
||||
component keys in the dir
|
||||
+ Look in app dirs for required components
|
||||
+ Do not use and install gnome-wm by default
|
||||
+ Add command line option to override the gconf key used to look up the
|
||||
default session
|
||||
+ Fix add/edit dialog of the capplet
|
||||
+ Fix leaks
|
||||
+ Code cleanups
|
||||
+ Translation updates
|
||||
- Removed gnome-session-launch-dbus.patch. Fixed upstream.
|
||||
- Removed gnome-session-bgo550211-gnome-session-save-logout.patch.
|
||||
Fixed upstream
|
||||
* Mon Sep 01 2008 vuntz@novell.com
|
||||
- Remove gnome-session-tile-ui.patch and add instead
|
||||
gnome-session-bgo507101-tile-ui.patch that implements the
|
||||
|
Loading…
Reference in New Issue
Block a user