summaryrefslogtreecommitdiff
path: root/coreutils/echo.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* *: make GNU licensing statement forms more regularDenys Vlasenko2010-08-161-1/+1
| | | | | | | This change retains "or later" state! No licensing _changes_ here, only form is adjusted (article, space between "GPL" and "v2" and so on). Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* *: introduce and use ffulsh_all()Denys Vlasenko2009-11-021-1/+1
| | | | | | | | | | | | | | | | | | | | function old new delta buffer_fill_and_print 179 196 +17 fflush_all - 9 +9 spawn 87 92 +5 rtcwake_main 455 453 -2 ... alarm_intr 93 84 -9 readcmd 1072 1062 -10 bb_ask 345 333 -12 more_main 845 832 -13 flush_stdout_stderr 42 23 -19 xfflush_stdout 27 - -27 flush_stderr 30 - -30 ------------------------------------------------------------------------------ (add/remove: 1/2 grow/shrink: 2/50 up/down: 31/-397) Total: -366 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* ash: dont allow e.g. exec <&10 to attach to stript's fd!Denis Vlasenko2008-07-251-4/+7
| | | | | | | | | | | | | function old new delta is_hidden_fd - 61 +61 redirect 1135 1164 +29 popstring 134 140 +6 printf_main 635 637 +2 evalvar 1374 1376 +2 echo_main 294 296 +2 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 5/0 up/down: 102/0) Total: 102 bytes
* *: rename ATTRIBUTE_XXX to just XXX.Denis Vlasenko2008-07-051-1/+1
|
* echo: fix echo -e -n "msg\n\0"Denis Vlasenko2008-04-301-4/+8
| | | | | (by "Pinedo, David" <david.pinedo AT hp.com>)
* shells: do not frocibly enable test, echo and kill _applets_,Denis Vlasenko2008-04-011-3/+1
| | | | | | | | | | | | | | | | | | | just build relevant source and use xxx_main functions. build system: add a special case when we have exactly one applet enabled (makes "true", "false", "basename" REALLY tiny). getopt32: do not use stdio. function old new delta getopt32 1385 1412 +27 make_device 1187 1200 +13 basename_main 120 127 +7 tcpudpsvd_main 1922 1926 +4 testcmd 5 - -5 echocmd 5 - -5 fuser_main 1243 1231 -12 ------------------------------------------------------------------------------ (add/remove: 0/2 grow/shrink: 4/1 up/down: 51/-22) Total: 29 bytes
* *: add -Wunused-parameter; fix resulting breakageDenis Vlasenko2008-03-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta procps_scan 1265 1298 +33 aliascmd 278 283 +5 parse_file_cmd 116 120 +4 dname_enc 373 377 +4 setcmd 90 93 +3 execcmd 57 60 +3 count_lines 72 74 +2 process_command_subs 340 339 -1 test_main 409 407 -2 mknod_main 179 177 -2 handle_incoming_and_exit 2653 2651 -2 argstr 1312 1310 -2 shiftcmd 131 128 -3 exitcmd 46 43 -3 dotcmd 297 294 -3 breakcmd 86 83 -3 evalpipe 353 349 -4 evalcommand 1180 1176 -4 evalcmd 109 105 -4 send_tree 374 369 -5 mkfifo_main 82 77 -5 evalsubshell 152 147 -5 typecmd 75 69 -6 letcmd 61 55 -6 add_cmd 1190 1183 -7 main 891 883 -8 ash_main 1415 1407 -8 parse_stream 1377 1367 -10 alloc_procps_scan 55 - -55 ------------------------------------------------------------------------------ (add/remove: 0/1 grow/shrink: 7/21 up/down: 54/-148) Total: -94 bytes text data bss dec hex filename 797195 658 7428 805281 c49a1 busybox_old 797101 658 7428 805187 c4943 busybox_unstripped
* nameif: extended matching (Nico Erfurth <masta@perlgolf.de>)Denis Vlasenko2007-12-241-1/+1
| | | | | | | | | | | | *: whitespace fixes function old new delta prepend_new_eth_table - 304 +304 nameif_main 620 684 +64 cc_macaddr 51 - -51 ------------------------------------------------------------------------------ (add/remove: 1/1 grow/shrink: 1/0 up/down: 368/-51) Total: 317 bytes
* remove echo_main -> bb_echo indirectionDenis Vlasenko2007-11-241-12/+8
|
* ash: fix bug where redirection of closed fd was leaving it open afterwards.Denis Vlasenko2007-11-221-2/+139
| | | | | | | | | | | | | | | | redirect 983 1024 +41 bb_echo 276 301 +25 popredir 118 132 +14 evalcommand 1163 1176 +13 bbunpack 358 366 +8 echocmd 13 5 -8 echo_main 13 5 -8 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 5/2 up/down: 101/-16) Total: 85 bytes text data bss dec hex filename 774999 962 9236 785197 bfb2d busybox_old 775084 962 9236 785282 bfb82 busybox_unstripped
* add -fvisibility=hidden to CC flags, mark XXX_main functionsDenis Vlasenko2007-10-111-2/+2
| | | | | EXTERNALLY_VISIBLE. 5% size reduction of libbusybox.so
* introduce bb_putchar(). saves ~1800 on uclibc (less on glibc).Denis Vlasenko2007-09-271-3/+3
|
* echo: fix yet another buglet in non-fancy echoDenis Vlasenko2007-06-191-1/+1
|
* - fix invocation without any argumentBernhard Reutner-Fischer2007-06-081-2/+2
|
* echo: fix non-fancy echoDenis Vlasenko2007-06-061-1/+1
|
* usage.c: remove reference to busybox.hDenis Vlasenko2007-05-261-1/+1
| | | | | *: s/include "busybox.h"/include "libbb.h"
* make a few struct bb_applet members conditionalDenis Vlasenko2007-04-101-0/+2
| | | | | | rename sllep_and_die -> xfunc_die make fflush_stdout_and_exit NOFORK-safe fix some buglets found by randomconfig
* echo: fix regression ("echo" with no arguments didn't print newline.Denis Vlasenko2007-04-101-8/+11
| | | | | | | | | | | | | | | | | | | | | | | echo: use fputs if no options are given. Code growth ~15 bytes. Old: # time ./busybox find $bigdir -exec echo {} \; >/dev/null real 0m2.038s user 0m0.761s sys 0m0.953s New: # time ./busybox find $bigdir -exec echo {} \; >/dev/null real 0m1.781s user 0m0.781s sys 0m0.939s For comparison: without NOFORK: # time find $bigdir -exec echo {} \; >/dev/null real 1m51.129s user 0m38.442s sys 1m3.350s
* Implement first instance of NOFORK applet - echoDenis Vlasenko2007-04-091-37/+38
| | | | | | | | | find: use NOFORK/NOEXEC; small -exec buglet also eliminated vfork_daemon_rexec: honor PREFER_APPLETS echo: small size improvements find -exec echo {} \; with PREFER_APPLETS=y runs 4 times faster
* suppress warnings about easch <applet>_main() havingDenis Vlasenko2007-02-031-0/+1
| | | | no preceding prototype
* introduce LONE_CHAR (optimized strcmp with one-char string)Denis Vlasenko2006-12-211-2/+2
|
* remove bb_printf and the likeDenis Vlasenko2006-10-261-1/+1
|
* Remove all usage of the "register" storage class specifier."Robert P. J. Day"2006-07-011-1/+1
|
* made "test" an ash built-in.Paul Fox2006-06-081-12/+141
| | | | | | | | | | | | | | | | | | | moved the contents of libbb/bb_echo.c back into coreutils/echo.c, which is a more reasonable place for them than libbb. this forces anyone who wants echo and test to be builtin to ash to also have them available as applets. their cost is very small, and the number of people who wouldn't want them as applets is also very small. added warning about shell builtins vs. CONFIG_FEATURE_SH_STANDALONE_SHELL, which conflicts with their use. thanks to nathanael copa for debugging help. some string size optimization in test.c may have been lost with this commit, but this is a good new baseline.
* Robert P. Day removed 8 gazillion occurrences of "extern" on functionRob Landley2006-03-061-1/+1
| | | | definitions. (That should only be on prototypes.)
* implemented a builtin echo command in ash. moved the guts of thePaul Fox2005-08-091-138/+2
| | | | | | echo applet into libbb, and now call bb_echo() from both echo.c and ash.c
* Larry Doolittle writes:Eric Andersen2004-04-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | This is a bulk spelling fix patch against busybox-1.00-pre10. If anyone gets a corrupted copy (and cares), let me know and I will make alternate arrangements. Erik - please apply. Authors - please check that I didn't corrupt any meaning. Package importers - see if any of these changes should be passed to the upstream authors. I glossed over lots of sloppy capitalizations, missing apostrophes, mixed American/British spellings, and German-style compound words. What is "pretect redefined for test" in cmdedit.c? Good luck on the 1.00 release! - Larry
* Remove trailing whitespace. Update copyright to include 2004.Eric Andersen2004-03-151-4/+4
|
* Major coreutils update.Manuel Novoa III2003-03-191-60/+73
|
* Apply Vladimir's latest cleanup patch.Eric Andersen2001-04-091-1/+1
| | | | -Erik
* A nice patch from Larry Doolittle that adds -Wshadow andEric Andersen2001-03-211-3/+3
| | | | cleans up most of the now-revealed problems.
* It turns out that DODMALLOC was broken when I reorganized busybox.hEric Andersen2001-02-201-1/+1
| | | | | | 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
* Fix header file usage -- there were many unnecessary header files included inEric Andersen2001-01-271-0/+2
| | | | | | | 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
* Stop using TRUE and FALSE for exit status.Matt Kraai2000-12-011-1/+1
|
* Apply the BSD echo version submitted by Jonas Holmberg <jonas.holmberg@axis.com>Eric Andersen2000-11-291-29/+67
|
* Remove the BSD advertising clause, and replace it with a link to howEric Andersen2000-11-141-4/+4
| | | | the advertising clause has been retroactivly declared null and void.
* Renamed "internal.h" to the more sensible "busybox.h".Eric Andersen2000-09-251-1/+1
| | | | -Erik
* The result of getopt() is "int" and should be treated as suchPavel Roskin2000-07-171-1/+1
|
* Extract usage information into a separate file.Matt Kraai2000-07-161-12/+1
|
* Getopt'ed by Marc Nijdam <marc_nijdam@hp.com>Eric Andersen2000-07-141-12/+13
| | | | -Erik
* * Fix to tr so it recognizes standard escape sequences. Merged commonEric Andersen2000-07-051-23/+5
| | | | | | | escape seq. code from tr and echo into utility.c. Fix thanks to Matt Kraai <kraai@alumni.carnegiemellon.edu>. * This should close Bug #1015. Please test. -Erik
* Updates to a number of apps to remove warnings/compile errors under libc5.Eric Andersen2000-06-191-1/+1
| | | | | Tested under both libc5 and libc6 and all seems well with these fixes. -Erik
* * cp -fa now works as expected for symlinks (it didn't before)Erik Andersen2000-05-101-3/+6
| | | | | | * zcat works again (wasn't working since option parsing was broken) * more doc updates/more support for BB_FEATURE_SIMPLE_HELP -Erik
* More doc updates for BusyBox, with fixes to apps for bugs revealedErik Andersen2000-04-131-0/+11
| | | | | while trying to write docs . :-) -Erik
* Forgot these files...Erik Andersen2000-03-161-0/+126
-Erik