OpenBSD CVS

CVS log for src/usr.bin/tmux/paste.c


[BACK] Up to [local] / src / usr.bin / tmux

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.46 / (download) - annotate - [select for diffs], Tue Feb 7 10:56:04 2023 UTC (15 months, 1 week ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, HEAD
Changes since 1.45: +3 -6 lines
Diff to previous 1.45 (colored)

Remove old buffer when renaming rather than complaining, GitHub issue
3467 from Jean-Philippe Paradis.

Revision 1.45 / (download) - annotate - [select for diffs], Fri Oct 28 13:00:02 2022 UTC (18 months, 3 weeks ago) by nicm
Branch: MAIN
Changes since 1.44: +7 -7 lines
Diff to previous 1.44 (colored)

Add paste-buffer-deleted notification and fix name of paste-buffer-changed.

Revision 1.44 / (download) - annotate - [select for diffs], Mon Aug 15 09:10:34 2022 UTC (21 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2
Changes since 1.43: +12 -1 lines
Diff to previous 1.43 (colored)

Notify when a paste buffer is deleted, GitHub issue 3302 from George
Nachman.

Revision 1.43 / (download) - annotate - [select for diffs], Sat Jun 4 07:42:07 2022 UTC (23 months, 2 weeks ago) by nicm
Branch: MAIN
Changes since 1.42: +9 -1 lines
Diff to previous 1.42 (colored)

When picking a buffer because one isn't specified by the user, ignore
named buffers. GitHub issue 3212 from David le Blanc.

Revision 1.42 / (download) - annotate - [select for diffs], Sat May 16 15:35:19 2020 UTC (4 years ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.41: +2 -2 lines
Diff to previous 1.41 (colored)

Use VIS_CSTYLE for paste buffers also.

Revision 1.41 / (download) - annotate - [select for diffs], Sat May 16 15:24:28 2020 UTC (4 years ago) by nicm
Branch: MAIN
Changes since 1.40: +10 -1 lines
Diff to previous 1.40 (colored)

Add 'e' key in buffer mode to open the buffer in an editor.

Revision 1.40 / (download) - annotate - [select for diffs], Tue Apr 2 09:03:39 2019 UTC (5 years, 1 month ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.39: +7 -4 lines
Diff to previous 1.39 (colored)

Add an argument to copy commands to set the prefix for the buffer name,
allows buffers for different sessions to be named separately.

Revision 1.39 / (download) - annotate - [select for diffs], Tue Jan 24 13:28:33 2017 UTC (7 years, 3 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2, OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.38: +4 -2 lines
Diff to previous 1.38 (colored)

Shorten a long line, and don't leak buffer in paste_add if size is zero.

Revision 1.38 / (download) - annotate - [select for diffs], Wed Oct 12 09:07:58 2016 UTC (7 years, 7 months ago) by nicm
Branch: MAIN
Changes since 1.37: +2 -2 lines
Diff to previous 1.37 (colored)

Unused variable and missing time.h.

Revision 1.37 / (download) - annotate - [select for diffs], Tue Oct 11 13:45:47 2016 UTC (7 years, 7 months ago) by nicm
Branch: MAIN
Changes since 1.36: +3 -3 lines
Diff to previous 1.36 (colored)

Some other stuff that can be local to one file.

Revision 1.36 / (download) - annotate - [select for diffs], Mon Oct 10 13:54:47 2016 UTC (7 years, 7 months ago) by nicm
Branch: MAIN
Changes since 1.35: +13 -13 lines
Diff to previous 1.35 (colored)

Some more static.

Revision 1.35 / (download) - annotate - [select for diffs], Wed Oct 5 12:34:05 2016 UTC (7 years, 7 months ago) by nicm
Branch: MAIN
Changes since 1.34: +21 -2 lines
Diff to previous 1.34 (colored)

Keep buffer creation time and add accessors for it and the order number.

Revision 1.34 / (download) - annotate - [select for diffs], Tue Jan 19 15:59:12 2016 UTC (8 years, 4 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.33: +2 -2 lines
Diff to previous 1.33 (colored)

I no longer use my SourceForge address so replace it.

Revision 1.33 / (download) - annotate - [select for diffs], Thu Nov 12 11:09:11 2015 UTC (8 years, 6 months ago) by nicm
Branch: MAIN
Changes since 1.32: +3 -6 lines
Diff to previous 1.32 (colored)

Nuke the utf8 and status-utf8 options and make tmux only a UTF-8
terminal. We still support non-UTF-8 terminals outside tmux, but inside
it is always UTF-8 (as when the utf8 and status-utf8 options were on).

Revision 1.32 / (download) - annotate - [select for diffs], Tue Oct 27 15:58:42 2015 UTC (8 years, 6 months ago) by nicm
Branch: MAIN
Changes since 1.31: +2 -2 lines
Diff to previous 1.31 (colored)

Move struct options into options.c.

Revision 1.31 / (download) - annotate - [select for diffs], Mon Sep 14 13:22:02 2015 UTC (8 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.30: +1 -2 lines
Diff to previous 1.30 (colored)

Remove some extra blank lines.

Revision 1.30 / (download) - annotate - [select for diffs], Fri Sep 11 14:41:50 2015 UTC (8 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.29: +8 -31 lines
Diff to previous 1.29 (colored)

Merge delete-buffer into cmd-set-buffer.c and change the paste buffer
API so it has one paste_free() rather than free_top and free_name
(everywhere that uses it already has the right pointer).

Revision 1.29 / (download) - annotate - [select for diffs], Sat Aug 29 09:36:46 2015 UTC (8 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.28: +1 -30 lines
Diff to previous 1.28 (colored)

paste_send_pane can be merged into cmd-paste-buffer.c now.

Revision 1.28 / (download) - annotate - [select for diffs], Sat Aug 29 09:25:00 2015 UTC (8 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.27: +33 -3 lines
Diff to previous 1.27 (colored)

Move struct paste_buffer out of tmux.h.

Revision 1.27 / (download) - annotate - [select for diffs], Tue Apr 7 13:06:22 2015 UTC (9 years, 1 month ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.26: +4 -4 lines
Diff to previous 1.26 (colored)

When replacing, don't free the old paste until after the new one's name
has been copied. Fixes a use-after-free in window-copy.c. Bug reported
by J Raynor (who also provided a different fix).

Revision 1.26 / (download) - annotate - [select for diffs], Wed Nov 5 23:25:02 2014 UTC (9 years, 6 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.25: +3 -3 lines
Diff to previous 1.25 (colored)

Tidy up mode-mouse check.

Revision 1.25 / (download) - annotate - [select for diffs], Wed Oct 8 17:35:58 2014 UTC (9 years, 7 months ago) by nicm
Branch: MAIN
Changes since 1.24: +2 -2 lines
Diff to previous 1.24 (colored)

Add xreallocarray and remove nmemb argument from xrealloc.

Revision 1.24 / (download) - annotate - [select for diffs], Wed Oct 8 17:14:04 2014 UTC (9 years, 7 months ago) by nicm
Branch: MAIN
Changes since 1.23: +2 -2 lines
Diff to previous 1.23 (colored)

Use xrealloc(NULL, n, m) instead of xmalloc(n * m) to get overflow
check.

Revision 1.23 / (download) - annotate - [select for diffs], Mon Sep 1 21:50:18 2014 UTC (9 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.22: +3 -3 lines
Diff to previous 1.22 (colored)

Various minor style and spacing nits.

Revision 1.22 / (download) - annotate - [select for diffs], Mon Aug 25 13:13:19 2014 UTC (9 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.21: +4 -1 lines
Diff to previous 1.21 (colored)

Don't allow pasting into input-disabled panes, from Anish R Athalye.

Revision 1.21 / (download) - annotate - [select for diffs], Fri Jun 20 11:00:19 2014 UTC (9 years, 11 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.20: +3 -3 lines
Diff to previous 1.20 (colored)

Comment style nits.

Revision 1.20 / (download) - annotate - [select for diffs], Tue May 13 22:54:18 2014 UTC (10 years ago) by nicm
Branch: MAIN
Changes since 1.19: +10 -3 lines
Diff to previous 1.19 (colored)

Don't allow multiple buffers with the same name, from Thomas Adam.

Revision 1.19 / (download) - annotate - [select for diffs], Tue May 13 07:34:35 2014 UTC (10 years ago) by nicm
Branch: MAIN
Changes since 1.18: +157 -47 lines
Diff to previous 1.18 (colored)

Add support for named buffers. If you don't name a buffer, things work
much as before - buffers are automatically named "buffer0000",
"buffer0001" and so on and ordered as a stack. Buffers can be named
explicitly when creating ("loadb -b foo" etc) or renamed ("setb -b
buffer0000 -n foo"). If buffers are named explicitly, they are not
deleted when buffer-limit is reached. Diff from J Raynor.

Revision 1.18 / (download) - annotate - [select for diffs], Thu Apr 24 09:14:43 2014 UTC (10 years ago) by nicm
Branch: MAIN
Changes since 1.17: +27 -25 lines
Diff to previous 1.17 (colored)

There is no longer a need for a paste_stack struct or for global_buffers
to be global. Move to paste.c.

Revision 1.17 / (download) - annotate - [select for diffs], Wed Apr 2 18:12:18 2014 UTC (10 years, 1 month ago) by nicm
Branch: MAIN
Changes since 1.16: +13 -12 lines
Diff to previous 1.16 (colored)

Support UTF-8 with choose-buffer, from Kosuke ASAMI. Also make
buffer_sample bigger to let it trim at window right edge.

Revision 1.16 / (download) - annotate - [select for diffs], Mon Mar 31 21:39:31 2014 UTC (10 years, 1 month ago) by nicm
Branch: MAIN
Changes since 1.15: +2 -2 lines
Diff to previous 1.15 (colored)

Add setb -a to append and a copy mode append command, from J Raynor with
minor changes.

Revision 1.15 / (download) - annotate - [select for diffs], Mon Feb 17 23:07:03 2014 UTC (10 years, 3 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5
Changes since 1.14: +4 -2 lines
Diff to previous 1.14 (colored)

Fix memory leaks with paste_replace, based on changes from J Raynor.

Revision 1.14 / (download) - annotate - [select for diffs], Tue Nov 27 20:22:12 2012 UTC (11 years, 5 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3
Changes since 1.13: +27 -1 lines
Diff to previous 1.13 (colored)

Support middle-click paste, based on a diff from Ailin Nemui.

Revision 1.13 / (download) - annotate - [select for diffs], Tue Sep 4 13:24:50 2012 UTC (11 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.12: +3 -5 lines
Diff to previous 1.12 (colored)

Trivial code simplification from Tim Ruehsen.

Revision 1.12 / (download) - annotate - [select for diffs], Tue Jul 10 11:53:01 2012 UTC (11 years, 10 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_2_BASE, OPENBSD_5_2
Changes since 1.11: +9 -8 lines
Diff to previous 1.11 (colored)

xfree is not particularly helpful, remove it. From Thomas Adam.

Revision 1.11 / (download) - annotate - [select for diffs], Mon Mar 28 19:44:31 2011 UTC (13 years, 1 month ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.10: +2 -2 lines
Diff to previous 1.10 (colored)

Style: uint -> u_int and a missing else.

Revision 1.10 / (download) - annotate - [select for diffs], Thu Dec 30 23:16:18 2010 UTC (13 years, 4 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.9: +1 -14 lines
Diff to previous 1.9 (colored)

Change from a per-session stack of buffers to one global stack which is
much more convenient and also simplifies lot of code. This renders
copy-buffer useless and makes buffer-limit now a server option.

By Tiago Cunha.

Revision 1.9 / (download) - annotate - [select for diffs], Mon Jun 21 21:44:09 2010 UTC (13 years, 11 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.8: +26 -1 lines
Diff to previous 1.8 (colored)

Add a choose-buffer command for easier use of the paste buffer stack.

Revision 1.8 / (download) - annotate - [select for diffs], Thu Dec 3 22:50:10 2009 UTC (14 years, 5 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.7: +3 -3 lines
Diff to previous 1.7 (colored)

Massive spaces->tabs and trailing whitespace cleanup, hopefully for the last
time now I've configured emacs to make them displayed in really annoying
colours...

Revision 1.7 / (download) - annotate - [select for diffs], Thu Nov 26 22:28:24 2009 UTC (14 years, 5 months ago) by nicm
Branch: MAIN
Changes since 1.6: +26 -4 lines
Diff to previous 1.6 (colored)

Tidy up various bits of the paste code, make the data buffer char * and add
comments.

Revision 1.6 / (download) - annotate - [select for diffs], Tue Nov 3 17:17:24 2009 UTC (14 years, 6 months ago) by nicm
Branch: MAIN
Changes since 1.5: +1 -5 lines
Diff to previous 1.5 (colored)

tv member of struct paste_buffer is updated but not otherwise used, so remove
it.

Revision 1.5 / (download) - annotate - [select for diffs], Sun Sep 20 14:58:12 2009 UTC (14 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.4: +3 -3 lines
Diff to previous 1.4 (colored)

Regularise some fatal messages.

Revision 1.4 / (download) - annotate - [select for diffs], Mon Sep 7 18:50:45 2009 UTC (14 years, 8 months ago) by nicm
Branch: MAIN
Changes since 1.3: +5 -3 lines
Diff to previous 1.3 (colored)

Give each paste buffer a size member instead of requiring them to be
zero-terminated.

Revision 1.3 / (download) - annotate - [select for diffs], Thu Jul 30 20:50:54 2009 UTC (14 years, 9 months ago) by nicm
Branch: MAIN
Changes since 1.2: +6 -2 lines
Diff to previous 1.2 (colored)

Don't leak when rollling buffers off when the paste buffer limit is reached.

Revision 1.2 / (download) - annotate - [select for diffs], Thu Jul 2 16:15:43 2009 UTC (14 years, 10 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.1: +4 -1 lines
Diff to previous 1.1 (colored)

Fix two copy/paste bugs: forbid zero-length buffers to prevent a fatal error
when trying to paste them, found by me, and miscalculation of the start/end
causing random fatal errors when copying in copy-mode, reported by sthen.

ok sthen "put it in" deraadt

Revision 1.1 / (download) - annotate - [select for diffs], Mon Jun 1 22:58:49 2009 UTC (14 years, 11 months ago) by nicm
Branch: MAIN

Import tmux, a terminal multiplexor allowing (among other things) a single
terminal to be switched between several different windows and programs
displayed on one terminal be detached from one terminal and moved to another.

ok deraadt pirofti

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.