Xinqi Bao's Git
projects
/
st.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
raw
|
inline
| side by side
Changing the way how paste is handled, just for the nano people.
[st.git]
/
st.c
diff --git
a/st.c
b/st.c
index
9f5793c
..
8b5ba64
100644
(file)
--- a/
st.c
+++ b/
st.c
@@
-796,7
+796,7
@@
selcopy(void) {
}
/* \n at the end of every selected line except for the last one */
if(is_selected && y < sel.e.y)
}
/* \n at the end of every selected line except for the last one */
if(is_selected && y < sel.e.y)
- *ptr++ = '\
n
';
+ *ptr++ = '\
r
';
}
*ptr = 0;
}
}
*ptr = 0;
}
@@
-1295,7
+1295,6
@@
tnewline(int first_col) {
void
csiparse(void) {
void
csiparse(void) {
- /* int noarg = 1; */
char *p = csiescseq.buf, *np;
long int v;
char *p = csiescseq.buf, *np;
long int v;
@@
-1306,9
+1305,10
@@
csiparse(void) {
}
while(p < csiescseq.buf+csiescseq.len) {
}
while(p < csiescseq.buf+csiescseq.len) {
+ np = NULL;
v = strtol(p, &np, 10);
if(np == p)
v = strtol(p, &np, 10);
if(np == p)
-
break
;
+
v = 0
;
if(v == LONG_MAX || v == LONG_MIN)
v = -1;
csiescseq.arg[csiescseq.narg++] = v;
if(v == LONG_MAX || v == LONG_MIN)
v = -1;
csiescseq.arg[csiescseq.narg++] = v;