lineedit: return prefix len from tab completion helpers
authorDenys Vlasenko <dvlasenk@redhat.com>
Fri, 3 Sep 2010 10:56:36 +0000 (12:56 +0200)
committerDenys Vlasenko <dvlasenk@redhat.com>
Fri, 3 Sep 2010 10:56:36 +0000 (12:56 +0200)
commit3c460b005c3c422fe73dc464902e0626fc57938a
tree79d5d815280dac6d2f3e1c4cf534842c4ef4486e
parent2679e3c8cccbf3ae4cac8e735e5430ebbe714b00
lineedit: return prefix len from tab completion helpers

This kills horrific logic which deletes and re-adds prefix (!)

function                                             old     new   delta
complete_cmd_dir_file                                705     731     +26
complete_username                                    121     124      +3
input_tab                                           1041    1016     -25
build_match_prefix                                   838     804     -34
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/2 up/down: 29/-59)            Total: -30 bytes

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
libbb/lineedit.c