last_fancy -n rows and filtering

Sergey Naumov sknaumov at gmail.com
Wed May 18 19:35:15 UTC 2011


Hello.

Here is a first version of patch to last_fancy to support -n
<rows_to_show> flag and filtering by provided command line arguments.
Of course all changes are conditional.

bloat-o-meter (unselected conditionals vs unpatched busybox):
function                                             old     new   delta
last_main                                            860     870     +10
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/0 up/down: 10/0)               Total: 10 bytes

bloat-o-meter (selected conditionals vs unpatched busybox):
function                                             old     new   delta
show_entry                                           276     381    +105
last_main                                            860     889     +29
.rodata                                             1574    1580      +6
static.rows_shown                                      -       4      +4
rows_to_show                                           -       4      +4
filters                                                -       4      +4
------------------------------------------------------------------------------
(add/remove: 3/0 grow/shrink: 3/0 up/down: 152/0)             Total: 152 bytes

Code could be shrinked a bit if we will not support -n 0 case as "show
all" but "show nothing".
Any suggestions are welcomed.

Thanks in advance,
Sergey Naumov.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: busybox-1.19.0-last_fancy.patch
Type: text/x-patch
Size: 3668 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/busybox/attachments/20110518/78b2da15/attachment.bin>


More information about the busybox mailing list