aboutsummaryrefslogtreecommitdiffhomepage
path: root/kill.cpp
diff options
context:
space:
mode:
authorGravatar ridiculousfish <corydoras@ridiculousfish.com>2013-01-31 15:57:08 -0800
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2013-01-31 15:57:08 -0800
commitad8d68dd4390753901b5e1dae4b4c4b44be7fcea (patch)
tree5b8f5e3ca3d698dd7ae764f2833ab7b91726fd93 /kill.cpp
parent0db1b6ce44b2dcae94a4d33c04b606ef819bb78b (diff)
Make subcommands modify $status, and make builtin_set not modify status unless it fails
Diffstat (limited to 'kill.cpp')
-rw-r--r--kill.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/kill.cpp b/kill.cpp
index 846783e5..2f6790d8 100644
--- a/kill.cpp
+++ b/kill.cpp
@@ -112,7 +112,7 @@ void kill_add(const wcstring &str)
if (! cmd.empty())
{
- if (exec_subshell(cmd) == -1)
+ if (exec_subshell(cmd, false /* do not apply exit status */) == -1)
{
/*
Do nothing on failiure
@@ -175,7 +175,7 @@ static void kill_check_x_buffer()
wcstring cmd = L"xsel -t 500 -b";
wcstring new_cut_buffer=L"";
wcstring_list_t list;
- if (exec_subshell(cmd, list) != -1)
+ if (exec_subshell(cmd, list, false /* do not apply exit status */) != -1)
{
for (i=0; i<list.size(); i++)