Use saved pipe buffer offset when writing to pipe, from Nicolas Viennot.

This commit is contained in:
nicm 2015-12-31 18:14:13 +00:00
parent 2a1f27eb1a
commit f84d32ca5e

View File

@ -948,7 +948,7 @@ window_pane_read_callback(__unused struct bufferevent *bufev, void *data)
new_size = EVBUFFER_LENGTH(evb) - wp->pipe_off;
if (wp->pipe_fd != -1 && new_size > 0) {
new_data = EVBUFFER_DATA(evb);
new_data = EVBUFFER_DATA(evb) + wp->pipe_off;
bufferevent_write(wp->pipe_event, new_data, new_size);
}