mirror of
https://github.com/ckolivas/lrzip.git
synced 2026-03-09 14:33:51 +01:00
Remove references to deprecated library mode.
This commit is contained in:
parent
56ac0f1a51
commit
5ffe83f948
|
|
@ -452,7 +452,6 @@ struct rzip_control {
|
|||
const char *util_outfile;
|
||||
char delete_outfile;
|
||||
FILE *outputfile;
|
||||
char library_mode;
|
||||
int log_level;
|
||||
void (*info_cb)(void *data, int pct, int chunk_pct);
|
||||
void *info_data;
|
||||
|
|
@ -513,11 +512,7 @@ struct stream_info {
|
|||
static inline void __attribute__((format(printf, 6, 7))) print_stuff(const rzip_control *control, int level, unsigned int line, const char *file, const char *func, const char *format, ...)
|
||||
{
|
||||
va_list ap;
|
||||
if (control->library_mode && control->log_cb && (control->log_level >= level)) {
|
||||
va_start(ap, format);
|
||||
control->log_cb(control->log_data, level, line, file, func, format, ap);
|
||||
va_end(ap);
|
||||
} else if (control->msgout) {
|
||||
if (control->msgout) {
|
||||
va_start(ap, format);
|
||||
vfprintf(control->msgout, format, ap);
|
||||
va_end(ap);
|
||||
|
|
@ -528,11 +523,7 @@ static inline void __attribute__((format(printf, 6, 7))) print_stuff(const rzip_
|
|||
static inline void __attribute__((format(printf, 5, 6))) print_err(const rzip_control *control, unsigned int line, const char *file, const char *func, const char *format, ...)
|
||||
{
|
||||
va_list ap;
|
||||
if (control->library_mode && control->log_cb && (control->log_level >= 0)) {
|
||||
va_start(ap, format);
|
||||
control->log_cb(control->log_data, 0, line, file, func, format, ap);
|
||||
va_end(ap);
|
||||
} else if (control->msgerr) {
|
||||
if (control->msgerr) {
|
||||
va_start(ap, format);
|
||||
vfprintf(control->msgerr, format, ap);
|
||||
va_end(ap);
|
||||
|
|
|
|||
4
util.h
4
util.h
|
|
@ -43,8 +43,6 @@ static inline void __attribute__((format(printf, 5, 6))) fatal(const rzip_contro
|
|||
} else
|
||||
control->log_cb(control->log_data, 0, line, file, func, format, ap);
|
||||
va_end(ap);
|
||||
if (!control->library_mode)
|
||||
fatal_exit((rzip_control*)control);
|
||||
}
|
||||
#ifdef fatal
|
||||
# undef fatal
|
||||
|
|
@ -68,8 +66,6 @@ static inline void __attribute__((format(printf, 5, 6))) failure(const rzip_cont
|
|||
else
|
||||
control->log_cb(control->log_data, 0, line, file, func, format, ap);
|
||||
va_end(ap);
|
||||
if (!control->library_mode)
|
||||
fatal_exit((rzip_control*)control);
|
||||
}
|
||||
#ifdef failure
|
||||
# undef failure
|
||||
|
|
|
|||
Loading…
Reference in a new issue