aboutsummaryrefslogtreecommitdiff
path: root/deskutils/easystroke/files/patch-actiondb.cc
diff options
context:
space:
mode:
Diffstat (limited to 'deskutils/easystroke/files/patch-actiondb.cc')
-rw-r--r--deskutils/easystroke/files/patch-actiondb.cc20
1 files changed, 20 insertions, 0 deletions
diff --git a/deskutils/easystroke/files/patch-actiondb.cc b/deskutils/easystroke/files/patch-actiondb.cc
new file mode 100644
index 000000000000..cfbdf2ee92a4
--- /dev/null
+++ b/deskutils/easystroke/files/patch-actiondb.cc
@@ -0,0 +1,20 @@
+--- actiondb.cc.orig 2013-03-27 15:52:38 UTC
++++ actiondb.cc
+@@ -118,14 +118,9 @@ template<class Archive> void StrokeInfo::serialize(Arc
+ using namespace std;
+
+ void Command::run() {
+- pid_t pid = fork();
+- switch (pid) {
+- case 0:
+- execlp("/bin/sh", "sh", "-c", cmd.c_str(), NULL);
+- exit(1);
+- case -1:
+- printf(_("Error: can't execute command \"%s\": fork() failed\n"), cmd.c_str());
+- }
++ gchar* argv[] = {(gchar*) "/bin/sh", (gchar*) "-c", NULL, NULL};
++ argv[2] = (gchar *) cmd.c_str();
++ g_spawn_async(NULL, argv, NULL, G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, NULL);
+ }
+
+ ButtonInfo Button::get_button_info() const {