X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=zoom%2Fzoomtst10.c;h=b0abf153ebe16573592a846a97395d0b706cc676;hp=1ea14dd00ba5fe5b883e4b5a743eea2fdc3e67dd;hb=d84e4c3cd444d04aee7beeadb5bb0ae061ee24c9;hpb=1d5b77651a731db70204f77e7b8662ac4b4bfad4 diff --git a/zoom/zoomtst10.c b/zoom/zoomtst10.c index 1ea14dd..b0abf15 100644 --- a/zoom/zoomtst10.c +++ b/zoom/zoomtst10.c @@ -1,8 +1,7 @@ -/* $Id: zoomtst10.c,v 1.2 2006-10-24 08:26:25 adam Exp $ */ - -/** \file zoomtst10.c - \brief Synchronous single-target search using CCL conversion -*/ +/* This file is part of the YAZ toolkit. + * Copyright (C) Index Data + * See the file LICENSE for details. + */ #include #include @@ -22,11 +21,11 @@ int main(int argc, char **argv) if (argc != 3) { fprintf (stderr, "usage:\n%s target cclquery\n", *argv); - fprintf (stderr, " eg. bagel.indexdata.dk/gils "ti=utah"\n"); + fprintf (stderr, " eg. bagel.indexdata.dk/gils \"ti=utah\"\n"); exit (1); } - if (ZOOM_query_ccl2rpn(q, argv[2], + if (ZOOM_query_ccl2rpn(q, argv[2], "term t=l,r s=al\n" "ti u=4 s=pw\n", &ccl_error_code, &ccl_error_string, &ccl_error_pos)) { @@ -38,13 +37,13 @@ int main(int argc, char **argv) else { z = ZOOM_connection_new (argv[1], 0); - + if ((error = ZOOM_connection_error(z, &errmsg, &addinfo))) { fprintf (stderr, "Error: %s (%d) %s\n", errmsg, error, addinfo); exit (2); } - + r = ZOOM_connection_search (z, q); ZOOM_query_destroy(q); if ((error = ZOOM_connection_error(z, &errmsg, &addinfo))) @@ -59,6 +58,7 @@ int main(int argc, char **argv) /* * Local variables: * c-basic-offset: 4 + * c-file-style: "Stroustrup" * indent-tabs-mode: nil * End: * vim: shiftwidth=4 tabstop=8 expandtab