Commit Graph

93 Commits

Author SHA1 Message Date
Denis Vlasenko
a959588b80 Yet another silly little byte saving. couldn't -> cannot 2006-09-29 21:30:43 +00:00
Rob Landley
20cc6d567f Remove pointless "const". Bloatcheck says 0 bytes difference. 2006-09-12 21:42:17 +00:00
Denis Vlasenko
22dca23d52 archival: added O_TRUNC so that when we overwrite files on unpack,
we truncate them. Also spotted & fixed hard to trigger bug
          with extension handling.
2006-09-03 14:23:29 +00:00
Rob Landley
d921b2ecc0 Remove bb_ prefixes from xfuncs.c (and a few other places), consolidate
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-08-03 15:41:12 +00:00
Rob Landley
534374755d Cleaup read() and write() variants, plus a couple of new functions like
xlseek and fdlength() for the new mkswap.
2006-07-16 08:14:35 +00:00
"Robert P. J. Day"
801ab14013 Add one-line GPL boilerplate to numerous (but not all yet) source files. 2006-07-12 07:56:04 +00:00
"Robert P. J. Day"
edd9ca5743 More removal of "#if 0" content. 2006-07-01 14:52:12 +00:00
Rob Landley
9a202c9daa Patch from Denis Vlasenko: unlzma was make files with mode 777. Tweak
everything to do stat() and use xopen3().
2006-06-13 14:54:42 +00:00
Rob Landley
c5b1d4d6b1 Patch from Denis Vlasenko to add xstat() and use it. 2006-03-13 15:45:16 +00:00
Rob Landley
dfba741457 Robert P. Day removed 8 gazillion occurrences of "extern" on function
definitions.  (That should only be on prototypes.)
2006-03-06 20:47:33 +00:00
"Vladimir N. Oleynik"
6c35c7c976 usage bb_dev_null 2005-10-12 15:34:25 +00:00
Rob Landley
b7128c6236 Cleanup patch by Bernhard Fischer, removing unnecessary includes of
getopt.h, whitespace changes, typos, etc.
2005-09-11 01:05:30 +00:00
Glenn L McGrath
c6992feee3 Update my email address, document some of my tasks in the AUTHORS file 2004-04-25 05:11:19 +00:00
Eric Andersen
70060d25d2 s/fileno\(stdin\)/STDIN_FILENO/g
s/fileno\(stdout\)/STDOUT_FILENO/g
2004-03-27 10:02:48 +00:00
Eric Andersen
c7bda1ce65 Remove trailing whitespace. Update copyright to include 2004. 2004-03-15 08:29:22 +00:00
Glenn L McGrath
ab7780655b Use bb_getopt_ulflags, save 150 bytes. 2004-01-05 12:35:05 +00:00
Glenn L McGrath
5699b8525e Move from read_gz to the pipe()+fork() method.
open_transformer(), common code for pipe+fork.
Function pointer for read() no longer needed.
Allow inflate to be initialised with a specified buffer size to avoid
over-reading.
Reset static variables in inflate_get_next_window to fix a bug where
only the first file in a .zip would be be extracted.
2003-11-15 23:19:05 +00:00
Eric Andersen
cb81e6484d Update a bunch of docs. Run a script to update my email addr. 2003-07-14 21:21:08 +00:00
Manuel Novoa III
cad5364599 Major coreutils update. 2003-03-19 09:13:01 +00:00
Glenn L McGrath
bf1cc8b1b7 Make uncompress a seperate applet so it doesnt pull in all the gunzip code 2002-11-01 23:38:54 +00:00
Glenn L McGrath
9ef0944456 Allow the .Z prefix if compress support enabled 2002-11-01 22:11:53 +00:00
Glenn L McGrath
563ac6e789 Report errror if the first magic character doesnt match 2002-11-01 21:40:52 +00:00
Glenn L McGrath
5c99581880 Save status so we know if to delete compressed file 2002-09-30 05:30:29 +00:00
Glenn L McGrath
2e41d0cb77 Fix compress support and prevent a segfault 2002-09-27 06:46:02 +00:00
Glenn L McGrath
7ca04f328e New common unarchive code. 2002-09-25 02:47:48 +00:00
Glenn L McGrath
c3b7f7d6e7 chmod on the NEW file 2002-08-26 17:17:27 +00:00
Glenn L McGrath
abac53b33c Reorganise, make it just one function, remove -v option it didnt work properly anyway, dont setvbuf it doesnt make any difference in performance. 2002-08-24 14:32:17 +00:00
Glenn L McGrath
1ee52e8b14 Run through indent, use braces 2002-08-24 10:30:36 +00:00
Robert Griebl
d378c3149c Applied vodz' patches #49 and #50 (with a small correction in runshell.c)
#49: I found one memory overflow and memory leak in "ln" applet.
Last patch reduced also 54 bytes. ;)

#50: I found bug in loginutils/Makefile.in.
New patch have also new function to libbb and
aplied this to applets and other cosmetic changes.
2002-07-19 00:05:54 +00:00
Robert Griebl
7ac868460a gunzip'ing many files to stdout works now
Fixed a missing initialisation and made a for loop more readable.
2002-05-15 21:57:42 +00:00
Robert Griebl
081df62b92 Don't delete source file when decompressing to stdout
This is the normal GNU gunzip behaviour
2002-05-15 21:45:52 +00:00
Matt Kraai
a4a65e7f99 * archival/gunzip.c (gunzip_file): New.
(gunzip_main): Handle no arguments correctly.
2002-04-29 15:32:32 +00:00
Eric Andersen
d75ac02a4f Rework per how I did things in version in 0.60.3 so it can
properly uncompress multiple files now.
 -Erik
2002-04-13 09:10:34 +00:00
Eric Andersen
50e4d660ac Fix email addr 2002-04-06 05:15:46 +00:00
Matt Kraai
1f0c43668a Remove == TRUE' tests and convert != TRUE' and `== FALSE' tests to use !. 2001-12-20 23:13:26 +00:00
Matt Kraai
c8227639db Change strdup calls to xstrdup (patch from Steve Merrifield). 2001-11-12 16:57:27 +00:00
Glenn L McGrath
b028e08d35 Move setvbuf calls from gz_open() to calling functions, setvbuf is only supposed to be called prior to opening the stream, glibc tolerates later use, uclibc doesnt. 2001-07-13 06:43:03 +00:00
Glenn L McGrath
06a71cced2 Initialise in_file to stdin, so it wont crash if no source specified 2001-06-20 08:07:34 +00:00
Matt Kraai
117231c44f Make - read compressed data from stdin (thanks to Marius Groeger). 2001-05-22 14:23:02 +00:00
Glenn L McGrath
713b398700 woops, forgot the break statment 2001-05-07 12:06:37 +00:00
Glenn L McGrath
5bcfc9ba1a Tolerate -q argument, if -q is passed give a warning and continue rather than just fail 2001-05-07 12:01:58 +00:00
Eric Andersen
04095e58fb Move messages.c to libbb. Make each string in messages.c be its own .o file.
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-25 05:39:18 +00:00
Matt Kraai
53265546a6 Eliminate spurious warning, convert to getopt, and eliminate redundant check. 2001-04-18 16:05:34 +00:00
Matt Kraai
96dcd19b8a Fix a number of problems with argument handling. 2001-04-18 15:54:09 +00:00
Matt Kraai
54652230d4 Eliminate a segfault when called on an existing file with out an extension:
touch foo && gunzip foo
2001-04-18 15:51:45 +00:00
Glenn L McGrath
bcfeb2ac44 Fix zcat/gunzip when reading from stdin 2001-04-18 13:34:09 +00:00
Glenn L McGrath
7fd92949d0 Move unzip, gz_open, gz_close to libbb 2001-04-11 03:11:33 +00:00
Eric Andersen
3a6da8c183 gz_open and gz_close were left in, even when BB_FEATURE_TAR_GZIP was disabled.
Fix that.
2001-03-29 14:22:45 +00:00
Glenn L McGrath
5f2ef46d6d Fix zcat 2001-03-29 01:07:54 +00:00
Glenn L McGrath
ed7a776538 gunzip -c works again 2001-03-29 00:57:20 +00:00