[hackers] [st] Fixed copying empty lines inside selection. || Alexander

From: <git_AT_suckless.org>
Date: Tue, 27 May 2014 08:40:19 +0200

commit 2411308bd24c4db97a3bb06d38f183a679aec1ea
Author: Alexander <alex0player_AT_gmail.com>
Date: Mon May 26 09:23:56 2014 +0400

    Fixed copying empty lines inside selection.
    
    The code was assuming that empty lines have implicit wrap-around attribute.
    
    Signed-off-by: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>

diff --git a/st.c b/st.c
index 6424b54..506be0f 100644
--- a/st.c
+++ b/st.c
_AT_@ -949,7 +949,7 @@ getsel(void) {
                  * st.
                  * FIXME: Fix the computer world.
                  */
- if(y < sel.ne.y && x > 0 && !((gp-1)->mode & ATTR_WRAP))
+ if(y < sel.ne.y && !(x > 0 && (gp-1)->mode & ATTR_WRAP))
                         *ptr++ = '
';
 
                 /*
Received on Tue May 27 2014 - 08:40:19 CEST

This archive was generated by hypermail 2.3.0 : Tue May 27 2014 - 08:48:08 CEST