diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2008-06-20 18:45:35 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2008-06-20 18:45:35 +0000 |
commit | 3128de3f19e18c67626ba34523f6696b584c3f9e (patch) | |
tree | a00d8f203122e22528fb8c6f2291a6c32d0ea974 /window-copy.c | |
parent | ef1c1d57531bbfd762434524fd8e774cf5b9a140 (diff) |
buffer-limit option.
Diffstat (limited to 'window-copy.c')
-rw-r--r-- | window-copy.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/window-copy.c b/window-copy.c index 39f3bb6e..fc5708b0 100644 --- a/window-copy.c +++ b/window-copy.c @@ -1,4 +1,4 @@ -/* $Id: window-copy.c,v 1.20 2008-06-20 17:31:48 nicm Exp $ */ +/* $Id: window-copy.c,v 1.21 2008-06-20 18:45:35 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -362,7 +362,7 @@ window_copy_copy_selection(struct window *w, struct client *c) struct screen *s = &data->screen; char *buf; size_t len, off; - u_int i, xx, yy, sx, sy, ex, ey; + u_int i, xx, yy, sx, sy, ex, ey, limit; if (!s->sel.flag) return; @@ -415,7 +415,8 @@ window_copy_copy_selection(struct window *w, struct client *c) buf[off - 1] = '\0'; /* Add the buffer to the stack. */ - paste_add(&c->session->buffers, buf); + limit = options_get_number(&c->session->options, "buffer-limit"); + paste_add(&c->session->buffers, buf, limit); xfree(buf); } |