X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;ds=sidebyside;f=src%2Flibxml2_error.c;h=41d9284297ac59b47e7a9715b7896680fbbba75e;hb=52188379291c43d463d4ee6742cf81a700541723;hp=725b7cf3d8c2af9f30a19debddbe3f692ec9896d;hpb=8d691989077a0addcbd840d769dce6700f3d9622;p=yaz-moved-to-github.git diff --git a/src/libxml2_error.c b/src/libxml2_error.c index 725b7cf..41d9284 100644 --- a/src/libxml2_error.c +++ b/src/libxml2_error.c @@ -1,8 +1,6 @@ -/* - * Copyright (C) 2007, Index Data ApS +/* This file is part of the YAZ toolkit. + * Copyright (C) 1995-2008 Index Data * See the file LICENSE for details. - * - * $Id: libxml2_error.c,v 1.3 2007-01-03 08:42:15 adam Exp $ */ /** * \file libxml2_error.c @@ -12,6 +10,7 @@ #include #include #include +#include #include #if YAZ_HAVE_XML2 @@ -31,11 +30,7 @@ static void proxy_xml_error_handler(void *ctx, const char *fmt, ...) va_list ap; va_start(ap, fmt); -#ifdef WIN32 - vsprintf(buf, fmt, ap); -#else - vsnprintf(buf, sizeof(buf), fmt, ap); -#endif + yaz_vsnprintf(buf, sizeof(buf)-1, fmt, ap); yaz_log(libxml2_error_level, "%s: %s", (char*) ctx, buf); va_end (ap);