summaryrefslogtreecommitdiffstats
path: root/control-notify.c
diff options
context:
space:
mode:
authornicm <nicm>2019-12-12 11:39:56 +0000
committernicm <nicm>2019-12-12 11:39:56 +0000
commitc284ebe0ade7cc85ad6c3fe5ce7ed5108119222d (patch)
tree52fa29b04da1e5468bdce23cce61bf0370923c2e /control-notify.c
parent64fb7e472a9e627ee486707ab9d30b607d76478a (diff)
Rewrite the code for reading and writing files. Now, if the client is
not attached, the server process asks it to open the file, similar to how works for stdin, stdout, stderr. This makes special files like /dev/fd/X work (used by some shells). stdin, stdout and stderr and control mode are now just special cases of the same mechanism. This will also make it easier to use for other commands that read files such as source-file.
Diffstat (limited to 'control-notify.c')
-rw-r--r--control-notify.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/control-notify.c b/control-notify.c
index a1e2b7bf..babfcf2d 100644
--- a/control-notify.c
+++ b/control-notify.c
@@ -54,7 +54,7 @@ control_notify_input(struct client *c, struct window_pane *wp,
else
evbuffer_add_printf(message, "%c", buf[i]);
}
- control_write_buffer(c, message);
+ control_write(c, "%s", EVBUFFER_DATA(message));
evbuffer_free(message);
}
}