aboutsummaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2013-09-09Redo tail closer to the original design. Add more tests for large data sets. ↵Rob Landley
(Still no -f support yet.)
2013-09-09Fix [-group] argument dropping.Rob Landley
2013-09-03Replace ↵Rob Landley
for_each_pid_with_name_in_array_perform_callback_function_upon_translated_value() with name_to_pid(), comparing absolute paths or just basename() consistently as spotted by Lukasz Skalski, and adjust callers.
2013-09-06Ashwini Sharma submitted route.c, adding it to pending.Rob Landley
2013-09-06Make [-abc] exclude logic clear argument slots when disabling options.Rob Landley
2013-09-06Fix for xpidfile spotted by Felix Janda.Rob Landley
2013-09-03Introduce libbuf analogous to toybuf but for use by lib/*.c. Change ↵Rob Landley
readfile() semantics to be able to read into an existing buffer, or malloc its own if that's NULL.
2013-09-03Remove itoa/utoa, let libc do this with sprintf.Rob Landley
2013-09-01Improve --longopt parsing: general bugfixes, better error reporting, new ; ↵Rob Landley
option for optional arguments only suppliable with =.
2013-08-30Allow getmountlist to read fstab too.Rob Landley
2013-08-30Add scripts/single.sh to build individual non-multiplexed standalone commands.Rob Landley
Alas, you can't quite do this yet: make defconfig make for i in $(./toybox) do echo $i PREFIX=singles/ scripts/single.sh $i || break done Because the OLDTOY() aliases for commands won't build without the base command. And I can't just skip them because chown/chmod or mv/cp aren't the same thing.
2013-08-27Rewrite pmap to be simpler and match other implementation's output more closely.Rob Landley
2013-08-26syslogd: cleanupFelix Janda
- fix bugs introduced in the cleanups - inline addrfds() and open_unix_socks() and simplify them - use xpidfile() - remove isNetwork from struct logfile - invert the meaning of facility and level in struct logfile so that they are automatically correctly initialized - fix memory leak regarding the filenames of logfiles - TT.sd was unused
2013-08-18Remove files du no longer needs.Rob Landley
2013-08-10Add daemonize function to lib for klogd and syslogdFelix Janda
2013-08-08Achille Fouilleul pointed out that fdlength wasn't returning the right ↵Rob Landley
length in the binary search case. (This code was originally written for mke2fs, and applies to block devices. The regular file case should just return the length from stat. The ioctl is left commented out in case I want to add back code to check the size of CDROMs without spinning them up again; not sure the sector size is always right these days.)
2013-08-07Forgot to check in xfdopen(). My bad.Rob Landley
Failure of fdopen() is most likely failure of malloc() for the FILE structure.
2013-07-31Cleanup renice and implement '|' (required option) in argument parsing.Rob Landley
2013-07-19Start of TOYBOX_SINGLE support, for building standalone commands with no ↵Rob Landley
multiplexer.
2013-07-17Add timeout, factoring out common code from sleep.Rob Landley
2013-07-16Split lib/xwrap.c from lib/lib.cRob Landley
2013-07-14New stuff added to lib.c needs review too, so make a lib/pending.c and move ↵Rob Landley
several functions to it.
2013-07-12add grepStrake
2013-07-06This inlines CRC64, and nothing more.Isaac Dunham
The functions involved were called only once.
2013-06-22Option type @ counts number of occurrences, it doesn't take an argument.Rob Landley
2013-06-16Add xexit() and make error_exit() use it.Rob Landley
2013-06-02Stat cleanup.Rob Landley
lib: rename format_mode() to mode_to_string() (echoing string_to_mode), make it take a normal char * argument. stat: collapse big switch/case statements that only have one line each into if/else staircase (much fewer lines of code). Remove return type (other stat implementations print ? for unknown escapes, so do that here). Inline do_stat() and do_statfs(). Set default string in normal local variable "format". Remove unnecessary struct d. Restructure stat logic to "if (flagf && !statfs()) else if (!flagf && !stat()) else perror_msg();" Teach %N to add -> symlink. Judicious use of putchar() instead of xputc to let FILE * do its job collating output.
2013-06-01Add peek/poke to header file.Rob Landley
2013-06-01Enable readfile() and add peek() and poke() functions.Rob Landley
2013-05-19xioctl() error message should use hex ioctl number; that's what headers list.Rob Landley
2013-05-14Silence warning and comment a subtle bit.Rob Landley
2013-05-10Convert getmountlist() to xgetmountlist().Rob Landley
2013-04-30Fix bare longopts to set unique optflag bits.Rob Landley
2013-04-29Fix xabspath when last path component exists but we haven't got permissions ↵Rob Landley
to open it (ala readlink -f /dev/sda as a normal user). Spotted by Ashwini Sharma.
2013-04-29Fix conflicting types for show_help().Rob Landley
2013-04-22Add library function for the file permission formatting in ls and statFelix Janda
2013-04-26Add posix headers to toynet.h, move xioctl() to lib.c, introduce lib/net.c ↵Rob Landley
and move xsocket() to it.
2013-04-26Remove leaked global path_mounts.Rob Landley
2013-04-26Eliminate leaked global bunzip_errors.Rob Landley
2013-04-20More ifconfig cleanup.Rob Landley
2013-04-14Move guts of help command into show_help() in lib/help.c, with config ↵Rob Landley
TOYBOX_HELP controlling infrastructure.
2013-04-06Fix argument parsing so -- doesn't include itself in output.Rob Landley
2013-03-17Remove unused min/max macros.Rob Landley
2013-03-11Compile time probe to fish O_NOFOLLOW out of linux headers when fcntl ↵0.4.4Rob Landley
doesn't conform to posix-2008.
2013-03-09O_NOFOLLOW is specified by posix-2008 and varies by target, don't try to ↵Rob Landley
supply them for broken headers.
2013-02-24Comment updates and a policy statement about avoiding #define GNU_dammitRob Landley
2013-02-04More support for old (~2008) build environments, move the #ifdef checks for ↵Rob Landley
symbols out of specific library version checks (shouldn't hurt anything), remove obsolete debug macro.
2013-01-31Fix -in behavior: descend into existing directory without prompting, show ↵Rob Landley
full path in error messages, actually overwrite when answering yes to -i.
2013-01-17Fix xabspath() resolving symlink after .., and properly detecting failure ↵Rob Landley
for last entry after nondir.
2013-01-15Work around more random uClibc-specific breakage.Rob Landley