Fix off by one in `y' (transliterate) command which caused the last character
of the pattern space not to be examined. Noticed by: Motoyuki Konno <motoyuki@bsdclub.org>
This commit is contained in:
parent
742e9f76c3
commit
d1a1392d8f
@ -244,7 +244,7 @@ redirect:
|
||||
case 'y':
|
||||
if (pd || psl == 0)
|
||||
break;
|
||||
for (p = ps, len = psl; --len; ++p)
|
||||
for (p = ps, len = psl; len--; ++p)
|
||||
*p = cp->u.y[(unsigned char)*p];
|
||||
break;
|
||||
case ':':
|
||||
|
Loading…
x
Reference in New Issue
Block a user