aboutsummaryrefslogtreecommitdiff
path: root/miscutils/less.c
Commit message (Collapse)AuthorAgeFilesLines
* more of -Wall fixes from Cristian Ionescu-Idbohrn.Gravatar Denis Vlasenko2008-05-151-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some are fixing real bugs. function old new delta syslogd_main 938 958 +20 get_signum 136 143 +7 obj_load 777 782 +5 recv_from_to 210 214 +4 get_next_block 1795 1799 +4 display_topmem_process_list 1117 1121 +4 logread_main 484 487 +3 buffer_fill_and_print 73 76 +3 kill_main 687 689 +2 ll_remember_index 240 241 +1 do_stats 452 453 +1 if_readconf 166 165 -1 display_process_list 1192 1191 -1 run_applet_and_exit 507 505 -2 print_signames 33 31 -2 parse_one_line 1092 1090 -2 find_out_spec 57 55 -2 add_ksymoops_symbols 421 419 -2 ash_main 1407 1402 -5 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 11/8 up/down: 54/-17) Total: 37 bytes
* fix warnings about pointer signednessGravatar Denis Vlasenko2008-05-091-1/+1
|
* less: fix somewhat elusive case when less gets stuck in search modeGravatar Denis Vlasenko2008-04-131-6/+5
| | | | | | | function old new delta read_lines 719 730 +11 goto_match 141 116 -25
* *: s/BB_SIGS_FATAL/BB_FATAL_SIGS/ (latter proved easier to remember)Gravatar Denis Vlasenko2008-03-191-1/+1
| | | | | top: fix "top </dev/null" case (by Cristian Ionescu-Idbohrn)
* less: improve search when data is not supplied fast enough by stdin -Gravatar Denis Vlasenko2008-03-171-50/+64
| | | | | | | | | | | | | | | | | now will try reading for 1-2 seconds before declaring that there is no match. This fixes a very common annoyance with long manpages. function old new delta read_lines 653 719 +66 buffer_down 28 83 +55 goto_match 140 141 +1 cap_cur_fline 72 - -72 ------------------------------------------------------------------------------ (add/remove: 0/1 grow/shrink: 3/0 up/down: 122/-72) Total: 50 bytes text data bss dec hex filename 798734 661 7428 806823 c4fa7 busybox_old 798768 661 7428 806857 c4fc9 busybox_unstripped
* *: add optimization barrier to all "G trick" locationsGravatar Denis Vlasenko2008-02-271-8/+8
|
* less: shrinkGravatar Denis Vlasenko2008-02-241-24/+22
|
* less,klogd,syslogd,nc,tcpudp: exit on signal by killing itself, not exit(1)Gravatar Denis Vlasenko2008-02-241-3/+5
| | | | | *: minor shrink
* less: small shrinkGravatar Denis Vlasenko2008-02-231-11/+7
|
* less: make it a bit more resistant against statusline corruption.Gravatar Denis Vlasenko2008-02-231-11/+20
| | | | | | | | | | | | | | less: "examine" command will not bomb out on bad file name now less_main 1663 1694 +31 examine_file 87 114 +27 less_getch 138 160 +22 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 3/0 up/down: 80/0) Total: 80 bytes text data bss dec hex filename 798368 740 7484 806592 c4ec0 busybox_old 798470 740 7484 806694 c4f26 busybox_unstripped
* less: update line input so that it doesn't interfere withGravatar Denis Vlasenko2008-02-231-43/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | screen update. Makes "man bash", [enter], [/], <enter search pattern>, [enter] more usable - manpage draws as you enter the pattern! Yay!! less: fix bug where backspace wasn't actually deleting chars less: "examine file with empty name" doesn't abort anymore. libbb: add "all fatal signals" mask. getch_nowait - 207 +207 status_print - 105 +105 examine_file 64 87 +23 move_cursor - 16 +16 m_status_print 185 195 +10 less_main 1656 1663 +7 decode_format_string 790 795 +5 test_main 403 405 +2 process0_stdin 247 249 +2 passwd_main 1070 1072 +2 less_gets 196 178 -18 buffer_print 169 71 -98 less_getch 362 138 -224 ------------------------------------------------------------------------------ (add/remove: 3/0 grow/shrink: 7/3 up/down: 379/-340) Total: 39 bytes text data bss dec hex filename 798329 740 7484 806553 c4e99 busybox_old 798368 740 7484 806592 c4ec0 busybox_unstripped
* libbb: introduce bb_signals and bb_signals_recursive,Gravatar Denis Vlasenko2008-02-161-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | which sets same handler for many signals. sig_catch is nuked (bb_signals_recursive is more descriptive name). *: use them as appropriate. function old new delta bb_signals_recursive - 95 +95 bb_signals - 52 +52 run_command 258 273 +15 svlogd_main 1368 1377 +9 runsv_main 1746 1752 +6 runsvdir_main 1643 1646 +3 UNSPEC_print 64 66 +2 time_main 1128 1127 -1 ... resize_main 246 210 -36 sig_catch 63 - -63 set_fatal_sighandler 85 14 -71 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 5/24 up/down: 182/-548) Total: -366 bytes
* add -fvisibility=hidden to CC flags, mark XXX_main functionsGravatar Denis Vlasenko2007-10-111-1/+1
| | | | | EXTERNALLY_VISIBLE. 5% size reduction of libbusybox.so
* less: make 'f' page forwardGravatar Denis Vlasenko2007-09-271-1/+1
|
* introduce bb_putchar(). saves ~1800 on uclibc (less on glibc).Gravatar Denis Vlasenko2007-09-271-7/+7
|
* don't pass argc in getopt32, it's superfluousGravatar Denis Vlasenko2007-08-181-1/+1
| | | | | | | | (add/remove: 0/0 grow/shrink: 12/131 up/down: 91/-727) Total: -636 bytes text data bss dec hex filename 773469 1058 11092 785619 bfcd3 busybox_old 772644 1058 11092 784794 bf99a busybox_unstripped
* trylink: produce even more info about final link stageGravatar Denis Vlasenko2007-08-121-2/+2
| | | | | | | | | trylink: explain how to modify link and drastically decrease amount of padding (unfortunately, needs hand editing ATM). *: add ALIGN1 / ALIGN2 to global strings and arrays of bytes and shorts size saving: 0.5k
* less: add a bit more robustness in keyboard reading codeGravatar Denis Vlasenko2007-08-031-1/+3
|
* less: less <HUGEFILE + [End] busy loops, fix itGravatar Denis Vlasenko2007-05-311-1/+3
|
* less: forgot trivial #if ENABLE_xxxxGravatar Denis Vlasenko2007-05-311-0/+2
|
* more: stop using bssGravatar Denis Vlasenko2007-05-311-0/+2
| | | | | | | | | | | | | | # make && make bloatcheck function old new delta gotsig 86 107 +21 more_main 777 781 +4 cin_fileno 4 - -4 set_tty_to_initial_mode 25 - -25 new_settings 120 60 -60 initial_settings 120 60 -60 ------------------------------------------------------------------------------ (add/remove: 0/2 grow/shrink: 2/2 up/down: 25/-149) Total: -124 bytes
* less: fix very obscure memory corruption bugGravatar Denis Vlasenko2007-05-311-7/+38
|
* less: stop using data/bss. Code got smaller too.Gravatar Denis Vlasenko2007-05-311-47/+82
| | | | | | | | | | | | # size busybox_old busybox_unstripped text data bss dec hex filename 700719 2896 17880 721495 b0257 busybox_old 700547 2832 17432 720811 affab busybox_unstripped # size */*/less.o text data bss dec hex filename 6861 50 344 7255 1c57 busybox.t0/miscutils/less.o 6657 0 0 6657 1a01 busybox.t1/miscutils/less.o
* usage.c: remove reference to busybox.hGravatar Denis Vlasenko2007-05-261-1/+1
| | | | | *: s/include "busybox.h"/include "libbb.h"
* less: fix case when regex search finds nothingGravatar Denis Vlasenko2007-05-091-1/+7
|
* fix accumulated whitespace and indentation damageGravatar Denis Vlasenko2007-03-201-1/+1
|
* more: do not mess with "/dev/console" (!);Gravatar Denis Vlasenko2007-03-101-2/+3
| | | | | | | fill whole 1st screen (was "screen sans one line"); fall back to cat if redirected or no ctty less: fall back to cat if no ctty (was exiting) resize: cosmetics
* less: handle yet another Home/End key sequence; expand a commentGravatar Denis Vlasenko2007-03-091-4/+13
|
* less: make '/' (regex search) scan input if no matches are foundGravatar Denis Vlasenko2007-03-081-8/+6
| | | | in input taken so far.
* less: yet another attempt to make search betterGravatar Denis Vlasenko2007-03-081-1/+17
|
* less: fix 'n'ext match: sometimes was going to 999999th lineGravatar Denis Vlasenko2007-03-081-10/+19
|
* clean up accumulated whitespace damageGravatar Denis Vlasenko2007-03-071-2/+2
|
* less: support xterm's home/end; improve forward searchGravatar Denis Vlasenko2007-02-141-8/+28
|
* suppress warnings about easch <applet>_main() havingGravatar Denis Vlasenko2007-02-031-0/+1
| | | | no preceding prototype
* less: fix <tab><backspace> bugletGravatar Denis Vlasenko2006-12-311-5/+5
|
* less: interpret backspace.Gravatar Denis Vlasenko2006-12-311-0/+13
| | | | | less is officially declared PAGER-capable! ;) (this includes viewing of manpages)
* fixes from Yann E. MORIN <yann.morin.1998@anciens.enib.fr>Gravatar Denis Vlasenko2006-12-311-1/+1
|
* done a dozen of randconfig test. guess what? ALL failed...Gravatar Denis Vlasenko2006-12-301-2/+8
| | | | these are resulting fixes
* less: fix regexp search '/' on large filesGravatar Denis Vlasenko2006-12-251-47/+71
|
* small stupid changes. no code changesGravatar Denis Vlasenko2006-12-241-7/+3
|
* less: implement waiting for input using select(). Rather tricky business.Gravatar Denis Vlasenko2006-12-241-454/+516
| | | | But we do not read entire input anymore up-front.
* less: a few fixes for cases where we overflow status lineGravatar Denis Vlasenko2006-12-211-59/+31
|
* less: restore TAB display (was showing as inverse I after prev changes :)Gravatar Denis Vlasenko2006-12-211-29/+35
|
* less: "(null)" is a bit strange. "standard input" is better :)Gravatar Denis Vlasenko2006-12-211-5/+14
|
* less: how many different kinds of status line we need, three?!Gravatar Denis Vlasenko2006-12-211-43/+40
| | | | | small fixes. [prev commit also added control char filtering on input (e.g. regexp input, filename input for 'E' etc)]
* less: stop dying on bad regexps, quietly pipe data w/oGravatar Denis Vlasenko2006-12-211-110/+146
| | | | | user interaction if stdout is not a tty. size optimizations
* less: total cleanup and bugfix.Gravatar Denis Vlasenko2006-12-211-248/+236
| | | | | | | | | | | | | | Doesn't die horribly on binary files anymore. In fact, they _100%_ work now. Control chars are in reverse video, including DEL and that idiocy of VT-10x, Meta-ESC [inventor of which should be prohibited from reproducing]. Regex search is fixed also. When you specify search ('/' key), control chars turn into dots (unhighlighted), and found occurrences highlighted instead. This is reversible. Memory management fixed (was leaky as hell) and optimized. Linewrapping fixed and thoroughly tested. Max buffer size made configurable. ~ 600 bytes saved.
* less: somewhat buggy applet, but nice. Muchly reducedGravatar Denis Vlasenko2006-12-201-212/+201
| | | | | | | | xstrdup'ing and memory consumption. Made linewrap saner. regex matching code was awful - still buggy, but not as leaky as before. Made buffer size configurable. Killed several static and on-stack buffers. Hopefully eliminated staircase effect on Ctrl-C (unable to reproduce).
* - shrink less.Gravatar Bernhard Reutner-Fischer2006-12-041-56/+49
| | | | | | | | | | | | | | | | | 01a: svn version 01b: merge past_eof and inp_stdin into flags. 01c: merge match_backwards into flags. 01d: add handling of <HOME> and <END> keys, remove set_tty_raw, use fflush_stdout_and_exit 01e: rewrite special-key handling to be smaller. 01f: changing the format saves 4 bytes (alot of places would benefit from this) text data bss dec hex filename 9034 8 648 9690 25da less.o.01a 9023 8 640 9671 25c7 less.o.01b 9027 8 636 9671 25c7 less.o.01c 9068 8 636 9712 25f0 less.o.01d 8990 8 636 9634 25a2 less.o.01e 8986 8 636 9630 259e less.o.01f
* remove bb_printf and the likeGravatar Denis Vlasenko2006-10-261-13/+26
|