X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=src%2Felementset.c;h=07400c756c124a7f7f5f5c529641e49e8b782b72;hp=8e2bf9a87365ea8ba7c6ccad509ed3d1183bfe2f;hb=379504a233e3e2cc85bca1e7b6d864f1395aec7c;hpb=8d691989077a0addcbd840d769dce6700f3d9622 diff --git a/src/elementset.c b/src/elementset.c index 8e2bf9a..07400c7 100644 --- a/src/elementset.c +++ b/src/elementset.c @@ -1,8 +1,6 @@ -/* - * Copyright (C) 1995-2007, Index Data ApS +/* This file is part of the YAZ toolkit. + * Copyright (C) 1995-2009 Index Data * See the file LICENSE for details. - * - * $Id: elementset.c,v 1.3 2007-01-03 08:42:15 adam Exp $ */ /** * \file elementset.c @@ -33,10 +31,12 @@ const char *yaz_get_esn(Z_RecordComposition *comp) void yaz_set_esn(Z_RecordComposition **comp_p, const char *esn, NMEM nmem) { - Z_RecordComposition *comp = nmem_malloc(nmem, sizeof(*comp)); + Z_RecordComposition *comp = (Z_RecordComposition *) + nmem_malloc(nmem, sizeof(*comp)); comp->which = Z_RecordComp_simple; - comp->u.simple = nmem_malloc(nmem, sizeof(*comp->u.simple)); + comp->u.simple = (Z_ElementSetNames *) + nmem_malloc(nmem, sizeof(*comp->u.simple)); comp->u.simple->which = Z_ElementSetNames_generic; comp->u.simple->u.generic = nmem_strdup(nmem, esn); *comp_p = comp; @@ -47,6 +47,7 @@ void yaz_set_esn(Z_RecordComposition **comp_p, const char *esn, NMEM nmem) /* * Local variables: * c-basic-offset: 4 + * c-file-style: "Stroustrup" * indent-tabs-mode: nil * End: * vim: shiftwidth=4 tabstop=8 expandtab