diff options
author | Moritz Jodeit <moritz@cvs.openbsd.org> | 2005-02-24 09:44:37 +0000 |
---|---|---|
committer | Moritz Jodeit <moritz@cvs.openbsd.org> | 2005-02-24 09:44:37 +0000 |
commit | 51f873ed1f95a722c31a23c3235978deba558761 (patch) | |
tree | effe317f1c5e18c597e8eab6cab44602dbdb3b28 /usr.bin | |
parent | a93add44d60bfdf5e479dc5a5d5803e32591e398 (diff) |
remove docompress() completely in case of -DSMALL and
replace it with a better error message.
ok millert@ henning@
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/compress/main.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/usr.bin/compress/main.c b/usr.bin/compress/main.c index 4fd0f7a78c7..b26c984561f 100644 --- a/usr.bin/compress/main.c +++ b/usr.bin/compress/main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: main.c,v 1.58 2005/02/07 08:37:28 otto Exp $ */ +/* $OpenBSD: main.c,v 1.59 2005/02/24 09:44:36 moritz Exp $ */ #ifndef SMALL static const char copyright[] = @@ -36,7 +36,7 @@ static const char license[] = #endif /* SMALL */ #ifndef SMALL -static const char main_rcsid[] = "$OpenBSD: main.c,v 1.58 2005/02/07 08:37:28 otto Exp $"; +static const char main_rcsid[] = "$OpenBSD: main.c,v 1.59 2005/02/24 09:44:36 moritz Exp $"; #endif #include <sys/param.h> @@ -454,6 +454,7 @@ int docompress(const char *in, char *out, const struct compressor *method, int bits, struct stat *sb) { +#ifndef SMALL u_char buf[Z_BUFSIZE]; char *name; int error, ifd, ofd, flags; @@ -538,6 +539,10 @@ docompress(const char *in, char *out, const struct compressor *method, verbose_info(out, info.total_out, info.total_in, info.hlen); return (error); +#else + warnx("compression not supported"); + return (FAILURE); +#endif } const struct compressor * |