From 9af25502b9e14213d1d44e99e38f752c3a174b44 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Thu, 2 Dec 2004 11:28:20 +0000 Subject: [PATCH] Cosmtic changes. No code change in actual code --- test/api/safari1.c | 4 ++-- test/api/t1.c | 8 ++++---- test/api/t2.c | 10 +++++----- test/api/t3.c | 20 ++++++++++---------- test/api/t4.c | 38 +++++++++++++++++++------------------- test/api/t5.c | 8 ++++---- test/api/t6.c | 12 +++++------- test/api/t7.c | 19 +++++++++---------- test/api/t8.c | 10 ++++------ test/api/t9.c | 10 ++++------ test/api/xpath1.c | 8 ++++---- test/api/xpath2.c | 6 +++--- test/api/xpath3.c | 8 ++++---- test/api/xpath4.c | 10 ++++------ test/api/xpath5.c | 10 ++++------ 15 files changed, 85 insertions(+), 96 deletions(-) diff --git a/test/api/safari1.c b/test/api/safari1.c index 35c1051..a812639 100644 --- a/test/api/safari1.c +++ b/test/api/safari1.c @@ -1,4 +1,4 @@ -/* $Id: safari1.c,v 1.1 2004-11-29 21:55:28 adam Exp $ +/* $Id: safari1.c,v 1.2 2004-12-02 11:28:20 adam Exp $ Copyright (C) 2004 Index Data Aps @@ -47,7 +47,7 @@ int main(int argc, char **argv) zint ids[2]; ZebraService zs = start_up("safari.cfg", argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); init_data(zh, myrec); do_query(__LINE__, zh, "@attr 1=1016 the", 1); diff --git a/test/api/t1.c b/test/api/t1.c index 22cc182..8e89b73 100644 --- a/test/api/t1.c +++ b/test/api/t1.c @@ -1,5 +1,5 @@ -/* $Id: t1.c,v 1.10 2004-10-29 13:02:39 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002 +/* $Id: t1.c,v 1.11 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -28,7 +28,7 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA int main(int argc, char **argv) { ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/t2.c b/test/api/t2.c index d981787..20cf425 100644 --- a/test/api/t2.c +++ b/test/api/t2.c @@ -1,5 +1,5 @@ -/* $Id: t2.c,v 1.14 2004-10-29 13:02:39 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: t2.c,v 1.15 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -31,10 +31,10 @@ const char *myrec[] = { int main(int argc, char **argv) { ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); - init_data(zh,myrec); + init_data(zh, myrec); do_query(__LINE__,zh, "@attr 1=4 my", 1); - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/t3.c b/test/api/t3.c index 5d7caa5..1161644 100644 --- a/test/api/t3.c +++ b/test/api/t3.c @@ -1,5 +1,5 @@ -/* $Id: t3.c,v 1.12 2004-10-29 13:02:39 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: t3.c,v 1.13 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -35,9 +35,9 @@ int main(int argc, char **argv) { int i; ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); - init_data(zh,myrec); + init_data(zh, myrec); for (i = 0; i<4; i++) { @@ -64,17 +64,17 @@ int main(int argc, char **argv) yaz_pqf_destroy(parser); #if 0 /*FIXME Why is this disabled ??? */ - zebra_records_retrieve (zh, odr_output, setname, 0, - VAL_TEXT_XML, 1, &retrievalRecord); + zebra_records_retrieve(zh, odr_output, setname, 0, + VAL_TEXT_XML, 1, &retrievalRecord); #endif #if 1 zebra_deleleResultSet(zh, Z_DeleteRequest_list, 1, &setnamep, &status); #endif - odr_destroy (odr_input); - odr_destroy (odr_output); + odr_destroy(odr_input); + odr_destroy(odr_output); } - zebra_commit (zh); + zebra_commit(zh); - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/t4.c b/test/api/t4.c index 944b277..db76d62 100644 --- a/test/api/t4.c +++ b/test/api/t4.c @@ -1,5 +1,5 @@ -/* $Id: t4.c,v 1.12 2004-11-19 15:52:59 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: t4.c,v 1.13 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -34,19 +34,19 @@ int main(int argc, char **argv) { int i; ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); - init_data(zh,myrec); + init_data(zh, myrec); zebra_begin_trans (zh, 1); for (i = 0; i<1200; i++) - zebra_add_record (zh, myrec[0], strlen(myrec[0])); - zebra_end_trans (zh); + zebra_add_record(zh, myrec[0], strlen(myrec[0])); + zebra_end_trans(zh); zebra_close(zh); zebra_stop(zs); zs = start_service(""); - zh = zebra_open (zs); + zh = zebra_open(zs); zebra_select_database(zh, "Default"); for (i = 0; i<2; i++) @@ -54,34 +54,34 @@ int main(int argc, char **argv) ZebraRetrievalRecord retrievalRecord[1001]; char setname[20]; int j; - ODR odr_input = odr_createmem (ODR_DECODE); - ODR odr_output = odr_createmem (ODR_DECODE); + ODR odr_input = odr_createmem(ODR_DECODE); + ODR odr_output = odr_createmem(ODR_DECODE); YAZ_PQF_Parser parser = yaz_pqf_create(); Z_RPNQuery *query = yaz_pqf_parse(parser, odr_input, "@attr 1=4 my"); int hits; sprintf(setname, "s%d", i+1); - zebra_search_RPN (zh, odr_input, query, setname, &hits); + zebra_search_RPN(zh, odr_input, query, setname, &hits); yaz_pqf_destroy(parser); - odr_destroy (odr_input); + odr_destroy(odr_input); - zebra_begin_trans (zh, 1); + zebra_begin_trans(zh, 1); for (j = 0; j<1001; j++) retrievalRecord[j].position = j+1; - zebra_records_retrieve (zh, odr_output, setname, 0, - VAL_TEXT_XML, 1001, retrievalRecord); - + zebra_records_retrieve(zh, odr_output, setname, 0, + VAL_TEXT_XML, 1001, retrievalRecord); + - odr_destroy (odr_output); + odr_destroy(odr_output); - zebra_end_trans (zh); + zebra_end_trans(zh); } - zebra_commit (zh); - return close_down(zh,zs,0); + zebra_commit(zh); + return close_down(zh, zs, 0); } diff --git a/test/api/t5.c b/test/api/t5.c index 11b0f69..4153418 100644 --- a/test/api/t5.c +++ b/test/api/t5.c @@ -1,4 +1,4 @@ -/* $Id: t5.c,v 1.9 2004-10-29 13:02:39 heikki Exp $ +/* $Id: t5.c,v 1.10 2004-12-02 11:28:20 adam Exp $ Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 Index Data Aps @@ -33,9 +33,9 @@ const char *myrec[] = { int main(int argc, char **argv) { ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); - init_data(zh,myrec); + init_data(zh, myrec); do_query(__LINE__,zh, "@attr 1=4 my", 3); do_query(__LINE__,zh, "@attr 1=4 {my x}", 1); @@ -60,5 +60,5 @@ int main(int argc, char **argv) /* exl=1 distance=2 order=0 relation=3 (=), known, unit=word */ do_query(__LINE__,zh, "@prox 1 2 1 3 k 2 my x", 1); - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/t6.c b/test/api/t6.c index 23f2cef..52ae5e2 100644 --- a/test/api/t6.c +++ b/test/api/t6.c @@ -1,5 +1,5 @@ -/* $Id: t6.c,v 1.5 2004-10-29 13:02:39 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: t6.c,v 1.6 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -24,14 +24,12 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA #include "testlib.h" - int main(int argc, char **argv) { int i; ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); - srand(17); zebra_select_database(zh, "Default"); @@ -62,9 +60,9 @@ int main(int argc, char **argv) strcat(rec_buf, ""); zebra_add_record (zh, rec_buf, strlen(rec_buf)); - zebra_end_trans (zh); + zebra_end_trans(zh); zebra_close(zh); } - return close_down(0 /*zh*/ ,zs,0); + return close_down(0 /*zh*/, zs, 0); } diff --git a/test/api/t7.c b/test/api/t7.c index f943cbe..25b6cc6 100644 --- a/test/api/t7.c +++ b/test/api/t7.c @@ -1,4 +1,4 @@ -/* $Id: t7.c,v 1.4 2004-10-29 13:02:39 heikki Exp $ +/* $Id: t7.c,v 1.5 2004-12-02 11:28:20 adam Exp $ Copyright (C) 2004 Index Data Aps @@ -51,12 +51,11 @@ int main(int argc, char **argv) yaz_sort_spec (odr_output, "@attr 1=4 id"); int hits; - init_data(zh,recs); + init_data(zh, recs); - - zebra_begin_trans (zh, 0); + zebra_begin_trans(zh, 0); - zebra_search_RPN (zh, odr_input, query, setname1, &hits); + zebra_search_RPN(zh, odr_input, query, setname1, &hits); rc=zebra_sort(zh, odr_output, 1, &setname1, setname2, spec, &status); if (rc) @@ -72,17 +71,17 @@ int main(int argc, char **argv) exit(1); } - zebra_end_trans (zh); + zebra_end_trans(zh); yaz_pqf_destroy(parser); /* zebra_deleleResultSet(zh, Z_DeleteRequest_list, 1, &setnamep, &status); */ - odr_destroy (odr_input); - odr_destroy (odr_output); + odr_destroy(odr_input); + odr_destroy(odr_output); - zebra_commit (zh); + zebra_commit(zh); - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/t8.c b/test/api/t8.c index df74fd6..0aedd4e 100644 --- a/test/api/t8.c +++ b/test/api/t8.c @@ -1,5 +1,5 @@ -/* $Id: t8.c,v 1.5 2004-10-29 13:02:39 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: t8.c,v 1.6 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -24,8 +24,6 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA #include "testlib.h" - - const char *recs[] = { "\n" " My title\n" @@ -62,7 +60,7 @@ const char *recs[] = { int main(int argc, char **argv) { ZebraService zs = start_up("zebra8.cfg", argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open (zs); init_data(zh, recs); @@ -93,5 +91,5 @@ int main(int argc, char **argv) /* N=41 and N=49 get only rec2 */ Q( "@attr 2=3 @attr gils 1=2040 @attr 4=109 \"41 49\" ",1); - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/t9.c b/test/api/t9.c index bd91356..98d6fd8 100644 --- a/test/api/t9.c +++ b/test/api/t9.c @@ -1,5 +1,5 @@ -/* $Id: t9.c,v 1.3 2004-10-29 13:02:39 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: t9.c,v 1.4 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -22,7 +22,6 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA /** t9.c - test rank-1 */ - #include "testlib.h" #include "rankingrecords.h" @@ -33,7 +32,7 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA int main(int argc, char **argv) { ZebraService zs = start_up(0, argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); init_data(zh, recs); @@ -48,6 +47,5 @@ int main(int argc, char **argv) qry( zh, "@attr 1=1016 @attr 2=102 @or @or the foo bar", 3, "third title", 895 ); - - return close_down(zh,zs,0); + return close_down(zh, zs, 0); } diff --git a/test/api/xpath1.c b/test/api/xpath1.c index e6ddb0d..70fe3d4 100644 --- a/test/api/xpath1.c +++ b/test/api/xpath1.c @@ -1,5 +1,5 @@ -/* $Id: xpath1.c,v 1.2 2004-11-19 10:27:16 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: xpath1.c,v 1.3 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -41,8 +41,8 @@ int main(int argc, char **argv) 0}; zs = start_up("zebraxpath.cfg", argc, argv); - zh = zebra_open (zs); - init_data(zh,myrec); + zh = zebra_open(zs); + init_data(zh, myrec); do_query(__LINE__,zh, "@attr 1=/sgml/tag before", 0); do_query(__LINE__,zh, "@attr 1=/sgml/tag inside", 1); diff --git a/test/api/xpath2.c b/test/api/xpath2.c index f6409d9..2bcde1e 100644 --- a/test/api/xpath2.c +++ b/test/api/xpath2.c @@ -1,5 +1,5 @@ -/* $Id: xpath2.c,v 1.1 2004-10-29 14:16:22 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: xpath2.c,v 1.2 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -74,7 +74,7 @@ int main(int argc, char **argv) { ZebraService zs = start_up("zebraxpath.cfg", argc, argv); ZebraHandle zh = zebra_open (zs); - init_data(zh,myrec); + init_data(zh, myrec); do_query(__LINE__,zh, "@attr 1=/Zthes/termName Sauropoda", 1); do_query(__LINE__,zh, "@attr 1=/Zthes/relation/termName Sauropoda",1); diff --git a/test/api/xpath3.c b/test/api/xpath3.c index d7161d4..68a9020 100644 --- a/test/api/xpath3.c +++ b/test/api/xpath3.c @@ -1,6 +1,6 @@ -/* $Id: xpath3.c,v 1.1 2004-10-29 14:16:22 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: xpath3.c,v 1.2 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -40,8 +40,8 @@ const char *myrec[] = { int main(int argc, char **argv) { ZebraService zs = start_up("zebraxpath.cfg", argc, argv); - ZebraHandle zh = zebra_open (zs); - init_data(zh,myrec); + ZebraHandle zh = zebra_open(zs); + init_data(zh, myrec); #define q(qry,hits) do_query(__LINE__,zh,qry,hits) diff --git a/test/api/xpath4.c b/test/api/xpath4.c index 2c97f22..7983391 100644 --- a/test/api/xpath4.c +++ b/test/api/xpath4.c @@ -1,7 +1,5 @@ - - -/* $Id: xpath4.c,v 1.4 2004-11-05 18:08:06 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: xpath4.c,v 1.5 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -89,13 +87,13 @@ const char *myrec[] = { int main(int argc, char **argv) { ZebraService zs = start_up("zebraxpath.cfg", argc, argv); - ZebraHandle zh = zebra_open (zs); + ZebraHandle zh = zebra_open(zs); #if 0 yaz_log_init_level( yaz_log_mask_str_x("xpath4,rsbetween", LOG_DEFAULT_LEVEL)); #endif - init_data(zh,myrec); + init_data(zh, myrec); #define q(qry,hits) do_query(__LINE__,zh,qry,hits) diff --git a/test/api/xpath5.c b/test/api/xpath5.c index 1a102a6..aa20a3d 100644 --- a/test/api/xpath5.c +++ b/test/api/xpath5.c @@ -1,7 +1,5 @@ - - -/* $Id: xpath5.c,v 1.3 2004-11-05 17:44:32 heikki Exp $ - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004 +/* $Id: xpath5.c,v 1.4 2004-12-02 11:28:20 adam Exp $ + Copyright (C) 2003,2004 Index Data Aps This file is part of the Zebra server. @@ -62,8 +60,8 @@ const char *recs[] = { int main(int argc, char **argv) { ZebraService zs = start_up("zebraxpath.cfg", argc, argv); - ZebraHandle zh = zebra_open (zs); - init_data(zh,recs); + ZebraHandle zh = zebra_open(zs); + init_data(zh, recs); // yaz_log_init_level(LOG_ALL); -- 1.7.10.4