about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorMarco Peereboom <marco@conformal.com>2012-02-14 14:34:35 -0600
committerMarco Peereboom <marco@conformal.com>2012-02-14 14:34:35 -0600
commit70f8f3bf4791e4bbb9c28e2fe338c0d84b29ea0b (patch)
tree6a0f12c0cb9c7f9a27bb928e8fc8d9dbfa249981
parent90ae7caf5e036347c0c2d69aff1f9334877e09d4 (diff)
downloadxombrero-70f8f3bf4791e4bbb9c28e2fe338c0d84b29ea0b.tar.gz
add loudness flag on remote execution
-rw-r--r--unix.c6
-rw-r--r--xxxterm.c6
-rw-r--r--xxxterm.h2
3 files changed, 9 insertions, 5 deletions
diff --git a/unix.c b/unix.c
index 4ecf1ef..3bcf17a 100644
--- a/unix.c
+++ b/unix.c
@@ -17,8 +17,12 @@
 #include <xxxterm.h>
 
 int
-fork_exec(struct tab *t, char *argv0, const gchar *argv1, char *error)
+fork_exec(struct tab *t, char *argv0, const gchar *argv1, char *error, int loud)
 {
+
+	if (loud)
+		show_oops(t, "running: %s %s", argv0, argv1);
+
 	switch (fork()) {
 	case -1:
 		show_oops(t, error);
diff --git a/xxxterm.c b/xxxterm.c
index 41c6e18..e17f5f9 100644
--- a/xxxterm.c
+++ b/xxxterm.c
@@ -1318,7 +1318,7 @@ run_page_script(struct tab *t, struct karg *args)
 	else
 		strlcpy(script, tmp, sizeof script);
 
-	return (fork_exec(t, script, uri, "can't launch external script"));
+	return (fork_exec(t, script, uri, "can't launch external script", 1));
 }
 
 int
@@ -4588,7 +4588,7 @@ run_mimehandler(struct tab *t, char *mime_type, WebKitNetworkRequest *request)
 
 	return (fork_exec(t, m->mt_action,
 	    webkit_network_request_get_uri(request),
-	    "can't launch MIME handler"));
+	    "can't launch MIME handler", 0));
 }
 
 char *
@@ -4623,7 +4623,7 @@ run_download_mimehandler(char *mime_type, char *file)
 		return (1);
 
 	return (fork_exec(NULL, m->mt_action, file,
-	    "can't launch download MIME handler"));
+	    "can't launch download MIME handler", 0));
 }
 
 void
diff --git a/xxxterm.h b/xxxterm.h
index 3da786a..89a58cf 100644
--- a/xxxterm.h
+++ b/xxxterm.h
@@ -484,7 +484,7 @@ void		*input_check_mode(struct tab *);
 int		command_mode(struct tab *, struct karg *);
 
 /* OS specific */
-int		fork_exec(struct tab *, char *, const gchar *, char *);
+int		fork_exec(struct tab *, char *, const gchar *, char *, int);
 
 /* settings */
 #define XT_BM_NORMAL		(0)