diff --git a/exo-0.3.101-url-quoting.patch b/exo-0.3.101-url-quoting.patch new file mode 100644 index 0000000..7246847 --- /dev/null +++ b/exo-0.3.101-url-quoting.patch @@ -0,0 +1,66 @@ +diff -Nur exo-0.3.101.orig/exo-open/main.c exo-0.3.101/exo-open/main.c +--- exo-0.3.101.orig/exo-open/main.c 2009-04-11 04:09:56.000000000 -0600 ++++ exo-0.3.101/exo-open/main.c 2009-07-18 23:38:15.000000000 -0600 +@@ -35,7 +35,16 @@ + + #include + +- ++/** ++ * For testing this code the following commands should work: ++ * ++ * exo-open --launch WebBrowser http://xfce.org (bug #5461). ++ * exo-open http://xfce.org ++ * exo-open --launch TerminalEmulator ./script.sh 'something with a space' 'nospace' (bug #5132). ++ * exo-open --launch TerminalEmulator ssh -l username some.host.com ++ * xfterm4 -e ssh -l ssh -l username some.host.com (bug #5301, this generates line below) ++ * exo-open --launch TerminalEmulator 'ssh -l username some.host.com' ++ **/ + + static gboolean opt_help = FALSE; + static gboolean opt_version = FALSE; +@@ -142,6 +151,9 @@ + { + if (argc > 1) + { ++ ++ /* NOTE: see the comment at the top of this document! */ ++ + /* combine all specified parameters to one parameter string */ + join = g_string_new (NULL); + for (i = 1; argv[i] != NULL; i++) +@@ -150,10 +162,19 @@ + if (i > 1) + join = g_string_append_c (join, ' '); + +- /* append the quoted argument */ +- quoted = g_shell_quote (argv[i]); +- join = g_string_append (join, quoted); +- g_free (quoted); ++ /* only quote arguments with spaces if there are multiple ++ * arguments to be merged, this is a bit of magic to make ++ * common cares work property, see sample above with xfrun4 */ ++ if (argc > 2 && strchr (argv[i], ' ') != NULL) ++ { ++ quoted = g_shell_quote (argv[i]); ++ join = g_string_append (join, quoted); ++ g_free (quoted); ++ } ++ else ++ { ++ join = g_string_append (join, argv[i]); ++ } + } + parameter = g_string_free (join, FALSE); + } +@@ -162,6 +183,10 @@ + parameter = NULL; + } + ++#ifndef NDEBUG ++ g_message ("launch=%s, wd=%s, parameters (%d)=%s", opt_launch, opt_working_directory, argc, parameter); ++#endif ++ + /* run the preferred application */ + if (!exo_execute_preferred_application (opt_launch, parameter, opt_working_directory, NULL, &err)) + { diff --git a/exo.spec b/exo.spec index 768adca..f2bed2b 100644 --- a/exo.spec +++ b/exo.spec @@ -3,13 +3,14 @@ Summary: Application library for the Xfce desktop environment Name: exo Version: 0.3.101 -Release: 1%{?dist} +Release: 2%{?dist} # libexo-hal exo-helper mount-notify and exo-mount are all GPLv2+ # everything else is LGPLv2+ License: LGPLv2+ and GPLv2+ URL: http://xfce.org/ Source0: http://www.xfce.org/archive/xfce-4.6.1/src/exo-%{version}.tar.bz2 Patch0: exo-0.3.0-x86_64-build.patch +Patch1: exo-0.3.101-url-quoting.patch Group: System Environment/Libraries Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: dbus-glib >= 0.22 @@ -53,6 +54,7 @@ Python libraries and header files for the exo library. %setup -q %patch0 -p1 -b .x86_64-build +%patch1 -p1 -b .url-quoting %build %configure --enable-gtk-doc --disable-static @@ -134,6 +136,9 @@ fi %{python_sitearch}/pyexo.* %changelog +* Fri Jul 17 2009 Kevin Fenzi - 0.3.101-2 +- Add patch to fix url quoting (bug #509730) + * Sun Apr 19 2009 Kevin Fenzi - 0.3.101-1 - Update to 0.3.101