From: Martin Mares Date: Tue, 6 Jul 2004 10:19:44 +0000 (+0000) Subject: Complain loudly if anybody asks us to generate buckets of an unknown X-Git-Tag: holmes-import~974 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=0aa573644717b6501961de974cb51250a5f08b87;p=libucw.git Complain loudly if anybody asks us to generate buckets of an unknown type (this can happen e.g. in the buckettool). --- diff --git a/lib/obj2buck.c b/lib/obj2buck.c index afd4c1df..2a2fd1c9 100644 --- a/lib/obj2buck.c +++ b/lib/obj2buck.c @@ -18,7 +18,19 @@ static uns use_v33; void attr_set_type(uns type) { - use_v33 = (type == BUCKET_TYPE_V33 || type == BUCKET_TYPE_V33_LIZARD); + switch (type) + { + case BUCKET_TYPE_PLAIN: + case BUCKET_TYPE_V30: + use_v33 = 0; + break; + case BUCKET_TYPE_V33: + case BUCKET_TYPE_V33_LIZARD: + use_v33 = 1; + break; + default: + die("Don't know how to generate buckets of type %08x", type); + } } inline byte *