=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/paste.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- src/usr.bin/tmux/paste.c 2009/06/01 22:58:49 1.1 +++ src/usr.bin/tmux/paste.c 2009/07/02 16:15:43 1.2 @@ -1,4 +1,4 @@ -/* $OpenBSD: paste.c,v 1.1 2009/06/01 22:58:49 nicm Exp $ */ +/* $OpenBSD: paste.c,v 1.2 2009/07/02 16:15:43 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott @@ -100,6 +100,9 @@ paste_add(struct paste_stack *ps, char *data, u_int limit) { struct paste_buffer *pb; + + if (*data == '\0') + return; while (ARRAY_LENGTH(ps) >= limit) ARRAY_TRUNC(ps, 1);