]> granicus.if.org Git - procps-ng/commit
library: reduce overhead for another 'escape' function
authorJim Warner <james.warner@comcast.net>
Wed, 13 Jan 2021 06:00:00 +0000 (00:00 -0600)
committerCraig Small <csmall@dropbear.xyz>
Thu, 21 Jan 2021 06:30:24 +0000 (17:30 +1100)
commitba9560ff029a8e52acc48c8b8741a7f36d12ee25
tree9d403b96e2b2248ebbc4c187d5c0ed3916df09b9
parent031a08f2a76fcc4898b6c1619335512f3030d68a
library: reduce overhead for another 'escape' function

The preceding commit made that 'esc_all' function more
efficient by using direct pointer manipulation instead
of an indexed string reference approach within a loop.

This commit applies the same approach to the 'esc_ctl'
function. Now we'll save 12 more iterated instructions
while decreasing the function's code size by 43 bytes.

Signed-off-by: Jim Warner <james.warner@comcast.net>
proc/escape.c