X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=src%2Fodr_util.c;h=644c3c37c25fbcfdfc2f84209cd44bf7d104e021;hp=b42ee79302f3eb466e5af72adb80f6e1a292a2ad;hb=d02429b9a7fb8bb01961a51c2446eb1dce048c78;hpb=7a98e9bfbb9d5fe7d44822a9838e3becbdce9363 diff --git a/src/odr_util.c b/src/odr_util.c index b42ee79..644c3c3 100644 --- a/src/odr_util.c +++ b/src/odr_util.c @@ -1,8 +1,6 @@ -/* - * Copyright (C) 1995-2007, Index Data ApS +/* This file is part of the YAZ toolkit. + * Copyright (C) 1995-2012 Index Data * See the file LICENSE for details. - * - * $Id: odr_util.c,v 1.13 2007-05-08 08:22:36 adam Exp $ */ /** * \file odr_util.c @@ -14,16 +12,18 @@ #include #include -#include #include "odr-priv.h" #include void odr_prname(ODR o, const char *name) { - if (name) - odr_printf(o, "%*s%s ", o->op->indent*4, "", name); + if (o->op->indent < 16) + odr_printf(o, "%*s", o->op->indent * 2, ""); else - odr_printf(o, "%*s", o->op->indent*4, ""); + odr_printf(o, "level=%-7d%*s", o->op->indent, + 2 * (o->op->indent % 8) , ""); + if (name) + odr_printf(o, "%s ", name); } int odp_more_chunks(ODR o, const unsigned char *base, int len) @@ -119,6 +119,7 @@ char *odr_prepend(ODR o, const char *prefix, const char *old) /* * Local variables: * c-basic-offset: 4 + * c-file-style: "Stroustrup" * indent-tabs-mode: nil * End: * vim: shiftwidth=4 tabstop=8 expandtab