Commit graph

179 commits

Author SHA1 Message Date
Con Kolivas
0e76d5d67c Silence fallthrough warning. 2018-03-09 17:27:36 +11:00
Ingo Brückl
ad20a41940 Prevent lrunzip from decompressing with option 'i'
There must not be a decompression when requesting file information.
2018-03-09 15:48:33 +11:00
Ingo Brückl
6b50431410 Enable specifying the passphrase as an argument to option 'encrypt'
For various use cases it is desirable to be able to specify the
passphrase for a password protected encryption on the command line.

So allow option 'encrypt' to have an optional argument and set
control->passphrase to this argument if it is given.

Read the passphrase (and prompt for it) only from standard input
if not given on the command line.

Additionally, update documentation.

This fixes github issue #72, reported by aivanise.
2018-03-09 15:48:33 +11:00
ghost
14d95c7966 anonymous commit 2018-03-06 11:05:30 +00:00
ckolivas
4d8e60a912 Control window must be a positive value. 2017-12-18 09:08:27 +11:00
Con Kolivas
5a5c5cd425 Merge branch 'master' of github.com:ckolivas/lrzip 2016-10-17 19:53:02 +11:00
Con Kolivas
321c80f382 Add parsing of license option in compat mode and delete parsing of unused parameters where appropriate. 2016-10-17 19:50:45 +11:00
Jörg Plate
ae69bc45e5 fix getopt() call for 'p' by adding the missing colon (:) 2016-09-21 01:50:37 +02:00
Ole Tange
1203a1853e main.c: Ignore --lzma. 2016-06-11 21:47:54 +02:00
Con Kolivas
d05334bd86 checksum.buf should only be changed after the semaphore wait 2016-06-10 21:04:42 +10:00
Con Kolivas
7a03965214 Implement gzip compatible -r recursive option 2016-06-10 16:10:03 +10:00
Con Kolivas
8853f2e449 Add initial argument processing for recursive option 2016-06-10 12:57:34 +10:00
Con Kolivas
2021d5e862 Add one more verbose for compat mode 2016-06-09 18:14:43 +10:00
Con Kolivas
9a351d1b50 Add support for various combinations in compat mode 2016-06-09 18:02:13 +10:00
Con Kolivas
bed16a4272 Cosmetic help change for compat 2015-04-16 17:23:35 +10:00
Con Kolivas
fbd56ce9c7 Set STDOUT correctly in compat mode 2015-04-16 15:59:37 +10:00
Con Kolivas
3cfb993ce3 Show correct appname when called in compat mode 2015-04-16 15:18:11 +10:00
Con Kolivas
efe2ce91ca Add support for progress, fast and best flags in compat mode 2015-03-13 13:58:08 +11:00
ckolivas
90c8072deb Add compatibility mode with gzip 2015-03-13 13:02:54 +11:00
Con Kolivas
e6669cf156 Null terminate long options to find unhandled options 2015-03-10 14:02:51 +11:00
Con Kolivas
c951b17a20 Trivial date 2015-03-10 14:00:24 +11:00
Con Kolivas
9ac3990812 Add long option support 2015-03-10 13:52:22 +11:00
Con Kolivas
c14f9ccab3 Increase maxram when we abandon use of temporary input/output buffers 2015-03-03 14:15:09 +11:00
Con Kolivas
19396eb5af Merge pull request #30 from elmirjagudin/mem_limit_flag
command line option to limit memory usage
2015-02-09 09:21:09 +11:00
Chris Spiegel
fb3762ee97 Clear sa_mask and sa_handler before calling sigaction(). 2015-01-31 22:51:11 -08:00
Elmir Jagudin
14a824da2c added '-m' command line option
Added an option to override detected available ram. Can be used
to limit the amount of ram used by lrzip.
2014-06-18 16:24:19 +02:00
Con Kolivas
d8df50c9b7 Update various copyright dates. 2013-09-02 12:21:54 +10:00
Con Kolivas
1aa0c0fdd0 Fix crash with -S by not freeing control->suffix. 2012-07-13 10:40:41 +10:00
Con Kolivas
275523661d Revert "Fix invalid free error when -o and -S are used together."
This reverts commit 0d6944bd3f.

Breaks lrztar.
2012-07-13 10:38:29 +10:00
Con Kolivas
184a8f0025 Rename lrzip.h to lrzip_core.h to cope with case insensitive filesystems not working with Lrzip.h vs lrzip.h 2012-07-07 21:39:40 +10:00
Con Kolivas
0d6944bd3f Fix invalid free error when -o and -S are used together. 2012-07-07 21:02:35 +10:00
Con Kolivas
14c3ce2ab4 Calling lrzip via lrzcat would fail as the proper parameters weren't being passed to the control structure. Fix. 2012-03-10 20:47:57 +11:00
Con Kolivas
dbc71eceb1 Store a copy of the control struct to be reused on subsequent files to prevent variables being modified in the control struct on the first file that
corrupt compression/decompression of the 2nd file.
2012-03-07 22:19:14 +11:00
Con Kolivas
086265c83f Update copyright notices and style to 1TBS for return codes. 2012-03-07 22:04:24 +11:00
discomfitor
949c6d7a97 another semi-clusterfuck commit: *new logging macros *allow compression to and from any FILE, not just stdin/stdout *update main.c to work with the above 2011-08-17 20:59:41 +10:00
discomfitor
6dd20d735b giant clusterfuck commit: *add and use alloca/strdupa in some spots *implement return values on almost every function *free() is now a macro which also nulls the freed pointer *when in 'library mode', fatal_exit() will not be called *fatal()/failure() are now macros which add line number and file for logging *all occurrences of fatal/failure in files other than main.c are now wrapped to use a logging callback (if specified) and then return *functions now clean up resources on returning with an error 2011-08-17 20:59:40 +10:00
discomfitor
133b201867 move more code out of main.c, allocate outfile suffix 2011-08-17 20:59:40 +10:00
discomfitor
cbff8faef7 move liblrzip.h contents to lrzip_private.h global variables----- 2011-08-17 20:59:40 +10:00
discomfitor
e85e4df0ef move compression overhead calcs out of main() 2011-08-17 20:59:40 +10:00
discomfitor
1c64dcfb31 more initialization stuff out of main(), remove weird coincidentally successful one_g variable 2011-08-17 20:59:40 +10:00
discomfitor
cfd6915b20 move some initialization stuff out of main() 2011-08-17 20:59:40 +10:00
discomfitor
87120e0f75 use liblrzip.h defines in main.c 2011-08-17 20:59:40 +10:00
discomfitor
59f10b2c9c move functions+defines out of main.c 2011-08-17 20:59:40 +10:00
Con Kolivas
d033743e6f Add lrzcat symlink which automatically decompresses to stdout.
Revert automatic compression/decompression to stdout when not outputting to a tty, to be consistent with gzip.
2011-05-07 13:22:35 +10:00
Con Kolivas
5352debf15 Change to detecting only whether lrzip is inappropriately being passed a directory since there may be other valid file types. 2011-04-22 19:35:04 +10:00
Con Kolivas
e8824afa1b Do a sanity check on infile in lrzip to ensure it's working on a file it can compress. 2011-04-22 19:23:40 +10:00
Con Kolivas
30e990fbcf Add encrypt support to lrzip.conf 2011-04-22 18:49:24 +10:00
ckolivas
77f17857e7 Use STDOUT when no filename is specified and we detect stdout is not going to the terminal. 2011-04-20 11:56:02 +10:00
ckolivas
1456fcc0c6 Merge branch 'master' of github.com:ckolivas/lrzip 2011-04-13 15:02:35 +10:00
ckolivas
271e97d8be Update displayed compression window to match what will be used. 2011-04-13 14:24:02 +10:00