change from rob -- handle ^U like in rio, acme

This commit is contained in:
rsc 2003-11-23 17:53:32 +00:00
parent 422761f81e
commit 17f131946f

View file

@ -361,6 +361,10 @@ ctlw(Rasp *r, long o, long p)
long long
ctlu(Rasp *r, long o, long p) ctlu(Rasp *r, long o, long p)
{ {
if(--p < o)
return o;
if(raspc(r, p)=='\n')
return p;
for(; p-1>=o && raspc(r, p-1)!='\n'; --p) for(; p-1>=o && raspc(r, p-1)!='\n'; --p)
; ;
return p>=o? p : o; return p>=o? p : o;