From 6218bc5eb62acc2eb8fca37247c0de3d3e7a0325 Mon Sep 17 00:00:00 2001 From: Assar Westerlund Date: Wed, 21 Jun 2000 22:40:53 +0000 Subject: [PATCH] (length_type): fail on malloc error git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8444 ec53bebd-3082-4978-b11e-865c3cabbd6b --- lib/asn1/gen_length.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/asn1/gen_length.c b/lib/asn1/gen_length.c index c71cb5413..66bdacc08 100644 --- a/lib/asn1/gen_length.c +++ b/lib/asn1/gen_length.c @@ -61,7 +61,7 @@ length_type (const char *name, const Type *t, const char *variable) char *s; asprintf(&s, "(const int*)%s", name); if(s == NULL) - return ENOMEM; + errx (1, "out of memory"); length_primitive ("integer", s, variable); free(s); }