From: "Nirbheek Chauhan" <nirbheek@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/gnome:master commit in: x11-wm/mutter/, x11-wm/mutter/files/
Date: Fri, 29 Apr 2011 19:16:35 +0000 (UTC) [thread overview]
Message-ID: <74f208549efd045e73be0b08edb53594d567683f.nirbheek@gentoo> (raw)
commit: 74f208549efd045e73be0b08edb53594d567683f
Author: Nirbheek Chauhan <nirbheek <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 29 19:15:52 2011 +0000
Commit: Nirbheek Chauhan <nirbheek <AT> gentoo <DOT> org>
CommitDate: Fri Apr 29 19:15:52 2011 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=commit;h=74f20854
x11-wm/mutter: fix session saving, bug 363853
---
.../files/mutter-3.0.1-fix-session-saving.patch | 69 ++++++++++++++++++++
...{mutter-3.0.1.ebuild => mutter-3.0.1-r1.ebuild} | 6 ++
2 files changed, 75 insertions(+), 0 deletions(-)
diff --git a/x11-wm/mutter/files/mutter-3.0.1-fix-session-saving.patch b/x11-wm/mutter/files/mutter-3.0.1-fix-session-saving.patch
new file mode 100644
index 0000000..7352d2c
--- /dev/null
+++ b/x11-wm/mutter/files/mutter-3.0.1-fix-session-saving.patch
@@ -0,0 +1,69 @@
+From c248c57b6e48b230fc80e3bd53d0d41fb713848a Mon Sep 17 00:00:00 2001
+From: Matthias Clasen <mclasen@redhat.com>
+Date: Fri, 29 Apr 2011 11:23:30 +0000
+Subject: Make session saving work a bit better
+
+Previously, the restart command hardcoded "mutter" as the binary name.
+This commit changes it to use g_get_prgname() which has a better chance
+of being correct (and it does fix session saving for gnome-shell).
+
+Now that mutter is a library, it might be more correct (but also
+much higher overhead) to add api for setting these things from
+the outside.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=648828
+---
+diff --git a/src/core/session.c b/src/core/session.c
+index 65542f3..c19b17c 100644
+--- a/src/core/session.c
++++ b/src/core/session.c
+@@ -308,13 +308,16 @@ meta_session_init (const char *previous_client_id,
+ */
+ char hint = SmRestartIfRunning;
+ char priority = 20; /* low to run before other apps */
+-
++ const char *prgname;
++
++ prgname = g_get_prgname ();
++
+ prop1.name = SmProgram;
+ prop1.type = SmARRAY8;
+ prop1.num_vals = 1;
+ prop1.vals = &prop1val;
+- prop1val.value = "mutter";
+- prop1val.length = strlen ("mutter");
++ prop1val.value = (char *)prgname;
++ prop1val.length = strlen (prgname);
+
+ /* twm sets getuid() for this, but the SM spec plainly
+ * says pw_name, twm is on crack
+@@ -573,6 +576,9 @@ set_clone_restart_commands (void)
+ char *discardv[10];
+ int i;
+ SmProp prop1, prop2, prop3, *props[3];
++ const char *prgname;
++
++ prgname = g_get_prgname ();
+
+ /* Restart (use same client ID) */
+
+@@ -582,7 +588,7 @@ set_clone_restart_commands (void)
+ g_return_if_fail (client_id);
+
+ i = 0;
+- restartv[i] = "mutter";
++ restartv[i] = (char *)prgname;
+ ++i;
+ restartv[i] = "--sm-client-id";
+ ++i;
+@@ -603,7 +609,7 @@ set_clone_restart_commands (void)
+ /* Clone (no client ID) */
+
+ i = 0;
+- clonev[i] = "mutter";
++ clonev[i] = (char *)prgname;
+ ++i;
+ clonev[i] = NULL;
+
+--
+cgit v0.9
diff --git a/x11-wm/mutter/mutter-3.0.1.ebuild b/x11-wm/mutter/mutter-3.0.1-r1.ebuild
similarity index 91%
rename from x11-wm/mutter/mutter-3.0.1.ebuild
rename to x11-wm/mutter/mutter-3.0.1-r1.ebuild
index 0eee508..d33255c 100644
--- a/x11-wm/mutter/mutter-3.0.1.ebuild
+++ b/x11-wm/mutter/mutter-3.0.1-r1.ebuild
@@ -76,3 +76,9 @@ pkg_setup() {
$(use_enable introspection)
$(use_enable xinerama)"
}
+
+src_prepare() {
+ # https://bugs.gentoo.org/show_bug.cgi?id=363853
+ # Taken from upstream, remove for next release
+ epatch "${FILESDIR}/${P}-fix-session-saving.patch"
+}
next reply other threads:[~2011-04-29 19:16 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-29 19:16 Nirbheek Chauhan [this message]
-- strict thread matches above, loose matches on Subject: below --
2015-04-18 9:00 [gentoo-commits] proj/gnome:master commit in: x11-wm/mutter/, x11-wm/mutter/files/ Ole Reifschneider
2012-03-26 8:20 Nirbheek Chauhan
2011-10-18 7:37 Alexandre Restovtsev
2011-06-02 14:43 Nirbheek Chauhan
2011-03-29 8:35 Nirbheek Chauhan
2011-03-09 11:34 Nirbheek Chauhan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=74f208549efd045e73be0b08edb53594d567683f.nirbheek@gentoo \
--to=nirbheek@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox