X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=src%2Frecord_conv.c;h=671342c3e50bc0e0f7a1467e88f1598c9e25ac1e;hp=ff95f920039c246a56ce205daca42348eba23430;hb=d7c2d20fef26a64dd97469cc0b6bf02f9eb95981;hpb=2a7d35ce3d1bad977c9cf4f8d586e3699b4d20b3;ds=sidebyside diff --git a/src/record_conv.c b/src/record_conv.c index ff95f92..671342c 100644 --- a/src/record_conv.c +++ b/src/record_conv.c @@ -388,6 +388,10 @@ static void *construct_marc(const xmlNode *ptr, if (!info->input_charset && info->output_charset) info->input_charset = "utf-8"; } + else if (!strcmp(input_format, "json")) + { + info->input_format_mode = YAZ_MARC_JSON; + } else { wrbuf_printf(wr_error, "Element : " @@ -431,6 +435,12 @@ static void *construct_marc(const xmlNode *ptr, if (info->input_charset && !info->output_charset) info->output_charset = "utf-8"; } + else if (!strcmp(output_format, "json")) + { + info->output_format_mode = YAZ_MARC_JSON; + if (info->input_charset && !info->output_charset) + info->output_charset = "utf-8"; + } else { wrbuf_printf(wr_error, "Element : "