summaryrefslogtreecommitdiffhomepage
path: root/util-linux/more.c
AgeCommit message (Collapse)Author
2007-09-27introduce bb_putchar(). saves ~1800 on uclibc (less on glibc).Denis Vlasenko
2007-08-17assorted fixes for breakage found by randomconfigDenis Vlasenko
2007-08-15more: by Tristan Schmelcher <tpkschme@engmail.uwaterloo.ca>:Denis Vlasenko
- Fixed a number of deficiencies in the line wrapping. - Fixed a bug where the page could scroll multiple times per keypress. - Re-read terminal dimensions after user input, in case they resized the terminal while we were waiting. - Added an 'R' key to print the rest of the file without prompting. - Crudely support tabs in the line-wrapping code by converting them to 8 spaces.
2007-05-31more: stop using bssDenis Vlasenko
# 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
2007-05-26usage.c: remove reference to busybox.hDenis Vlasenko
*: s/include "busybox.h"/include "libbb.h"
2007-03-10more: do not mess with "/dev/console" (!);Denis Vlasenko
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
2007-02-17init: code readability enhancements; very small code changesDenis Vlasenko
2007-02-03suppress warnings about easch <applet>_main() havingDenis Vlasenko
no preceding prototype
2006-12-10more: fix for case when _FILE_OFFSET_BITS is not #defined.Denis Vlasenko
samll size improvement.
2006-10-26rename functions to more understandable namesDenis Vlasenko
2006-08-03Remove bb_ prefixes from xfuncs.c (and a few other places), consolidateRob Landley
things like xasprintf() into xfuncs.c, remove xprint_file_by_name() (it only had one user), clean up lots of #includes... General cleanup pass. What I've been doing for the last couple days. And it conflicts! I've removed httpd.c from this checkin due to somebody else touching that file. It builds for me. I have to catch a bus. (Now you know why I'm looking forward to Mercurial.)
2006-05-28Fix some warnings in allbareconfig.Rob Landley
2006-03-06Robert P. Day removed 8 gazillion occurrences of "extern" on functionRob Landley
definitions. (That should only be on prototypes.)
2004-03-27s/fileno\(stdin\)/STDIN_FILENO/gEric Andersen
s/fileno\(stdout\)/STDOUT_FILENO/g
2004-03-27Vladimir N. Oleynik (vodz) writes:Eric Andersen
Ok. Last patch reduce 73 bytes for compensate (and over) your changes ;-) Comments: Added cin_fileno variable, auto setted to 0 from BSS and have "eq" stdin descriptor if isatty(stout)==0, removed global variable FILE* cin. Removed default setting to terminal_width/terminal_height, this used only from main() and setted after call get_terminal_width_height() always correct. Variable please_display_more_prompt changed to bits logic, have size reducing. --w vodz
2004-03-23Brian Pomerantz writes:Eric Andersen
I've noticed a bug in the "autowidth" feature more, and is probably in others. The call to the function get_terminal_width_height() passes in a file descriptor but that file descriptor is never used, instead the ioctl() is called with 0. In more_main() the call to get_terminal_width_height() passes 0 as the file descriptor instead of fileno(cin). This isn't a problem when you more a file (e.g. "more /etc/passwd") but when you pipe a file to it (e.g. "cat /etc/passwd | more") the size of the terminal cannot be determined because file descriptor 0 is not a terminal. The fix is simple, I've attached a patch for more.c and get_terminal_width_height.c. BAPper
2004-03-15Remove trailing whitespace. Update copyright to include 2004.Eric Andersen
2003-12-23match changes made to cmdeditEric Andersen
2003-09-15Be entirely consistant when using ioctl(0, TIOCGWINSZ, &winsize)Eric Andersen
to ensure proper fallback behavior on, i.e. serial consoles. -Erik
2003-07-14Update a bunch of docs. Run a script to update my email addr.Eric Andersen
2003-03-19Major coreutils update.Manuel Novoa III
2003-01-13Correct some init issues, update email address, last_patch78 by VladimirGlenn L McGrath
N. Oleynik
2002-04-13Update some missing copyright noticesEric Andersen
2001-12-06Fix running more on files in the (broken) procfs that claim 0 lengthEric Andersen
when that isn't actually true. -Erik
2001-10-24Major rework of the directory structure and the entire build system.Eric Andersen
-Erik
2001-07-23Add support for devfs device names.Matt Kraai
2001-06-26Vladimir's last_patch_15Glenn L McGrath
2001-05-16Remove/replace the "div" call.Eric Andersen
2001-04-25Move messages.c to libbb. Make each string in messages.c be its own .o file.Eric Andersen
This way, we can new get rid of all that tedious #define rubbish we used to need to enable specific messages. This way is enormously simpler, and as a bonus also ends up saving us 96 bytes. -Erik
2001-04-12Fix return code and don't output spurious newlines.Matt Kraai
2001-04-06An optimization from VladimirEric Andersen
2001-04-05more FILE_OFFSET_BITS == 64 adjustments.Eric Andersen
2001-03-23Patch to use xfopen from Jeff GarzikEric Andersen
2001-02-23Yet another fix. I think I got it this time.Eric Andersen
-Erik
2001-02-22Account for remainder, and reset page_height for each and every page.Eric Andersen
2001-02-22Adjust the terminal height for any overlap, so that no linesEric Andersen
get lost off the top -Erik
2001-02-20It turns out that DODMALLOC was broken when I reorganized busybox.hEric Andersen
header file usage before the 0.49 release. To fix it, I had to move the '#include "busybox.h"' to the end of the list of #include files. -Erik
2001-02-02It seems I stupidly checked in a silly test I was making.Eric Andersen
-Erik
2001-02-01Apply a patch from Larry Doolittle to add "-all" and "-none" switchesEric Andersen
to multibuild.pl. I did a little formatting adjustments to make it _very_ obvious when things stop working. I also removed the USE_PROCFS config option -- just do the right thing when USE_DEVPS_PATCH is enabled. -Erik
2001-01-27Fix header file usage -- there were many unnecessary header files included inEric Andersen
busybox.h which slowed compiles. I left only what was needed and then fixed up all the apps to include their own header files. I also fixed naming for pwd.h and grp.h functions. Tested to compile and run with libc5, glibc, and uClibc. -Erik
2001-01-26Make cin be staticEric Andersen
2001-01-18Eliminate calls of the form "fprintf(stdout,". Thanks for the idea toMatt Kraai
Vladimir N. Oleynik.
2000-12-30Improvements from Vladimir N. Oleynik.Matt Kraai
2000-11-07Cleanup of duplicated symbols -- found by compiling withEric Andersen
LDFLAGS += -Wl,-warn-common
2000-09-27Consolidate handling of some fopen failures.Matt Kraai
2000-09-25Renamed "internal.h" to the more sensible "busybox.h".Eric Andersen
-Erik
2000-09-21Large file >2Gib support.Eric Andersen
2000-07-19Centralize handling of --help.Matt Kraai
2000-07-16Extract usage information into a separate file.Matt Kraai
2000-07-14More fixes for "missing initializers"Pavel Roskin