X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=src%2Fwrbuf.c;h=af5fb28be185e5036b7c0bb442f029c4eafad0c1;hp=e80f98a69e87b2d72b0b694c1f6bc00643f728ff;hb=c6b8edd2312a4606cc014738266059a20e3b6e61;hpb=ee6ab2ee3a9ee1a8c65d7272ec7fba1d886f5af0 diff --git a/src/wrbuf.c b/src/wrbuf.c index e80f98a..af5fb28 100644 --- a/src/wrbuf.c +++ b/src/wrbuf.c @@ -1,5 +1,5 @@ /* This file is part of the YAZ toolkit. - * Copyright (C) 1995-2008 Index Data + * Copyright (C) 1995-2009 Index Data * See the file LICENSE for details. */ @@ -78,6 +78,11 @@ int wrbuf_puts(WRBUF b, const char *buf) return 0; } +void wrbuf_vputs(const char *buf, void *client_data) +{ + wrbuf_write((WRBUF) client_data, buf, strlen(buf)); +} + int wrbuf_puts_replace_char(WRBUF b, const char *buf, const char from, const char to) { @@ -158,7 +163,7 @@ static int wrbuf_iconv_write_x(WRBUF b, yaz_iconv_t cd, const char *buf, { if (cd) { - char outbuf[16]; + char outbuf[128]; size_t inbytesleft = size; const char *inp = buf; while (inbytesleft) @@ -245,7 +250,7 @@ void wrbuf_cut_right(WRBUF b, size_t no_to_remove) void wrbuf_puts_escaped(WRBUF b, const char *str) { - return wrbuf_write_escaped(b, str, strlen(str)); + wrbuf_write_escaped(b, str, strlen(str)); } void wrbuf_write_escaped(WRBUF b, const char *str, size_t len) @@ -261,6 +266,7 @@ void wrbuf_write_escaped(WRBUF b, const char *str, size_t len) /* * Local variables: * c-basic-offset: 4 + * c-file-style: "Stroustrup" * indent-tabs-mode: nil * End: * vim: shiftwidth=4 tabstop=8 expandtab