Fixed bug #2068: pkg-config trouble.
[yaz-moved-to-github.git] / src / logrpn.c
index fa9a2ea..9972020 100644 (file)
@@ -2,7 +2,7 @@
  * Copyright (C) 1995-2007, Index Data ApS
  * All rights reserved.
  *
- * $Id: logrpn.c,v 1.16 2007-04-12 13:52:57 adam Exp $
+ * $Id: logrpn.c,v 1.18 2007-05-08 08:22:36 adam Exp $
  */
 
 /**
@@ -181,7 +181,7 @@ static void attrStr (int type, int value, char *str)
  * zlog_attributes: print attributes of term
  */
 static void zlog_attributes(Z_AttributesPlusTerm *t, int depth,
-                            const int *ast, int loglevel)
+                            const Odr_oid *ast, int loglevel)
 {
     int of, i;
     char str[80];
@@ -268,7 +268,7 @@ static char *prox_unit_name(Z_ProximityOperator *op)
 }
 
 static void zlog_structure(Z_RPNStructure *zs, int depth, 
-                           const int *ast, int loglevel)
+                           const Odr_oid *ast, int loglevel)
 {
     if (zs->which == Z_RPNStructure_complex)
     {
@@ -349,7 +349,7 @@ void log_rpn_query(Z_RPNQuery *rpn)
 }
 
 void log_scan_term_level(int loglevel, 
-                         Z_AttributesPlusTerm *zapt, const int *ast)
+                         Z_AttributesPlusTerm *zapt, const Odr_oid *ast)
 {
     int depth = 0;
     if (!loglevel)
@@ -364,7 +364,7 @@ void log_scan_term_level(int loglevel,
     zlog_attributes(zapt, depth+2, ast, loglevel);
 }
 
-void log_scan_term(Z_AttributesPlusTerm *zapt, const int *ast)
+void log_scan_term(Z_AttributesPlusTerm *zapt, const Odr_oid *ast)
 {
     log_scan_term_level (YLOG_LOG, zapt, ast);
 }
@@ -396,25 +396,6 @@ void yaz_log_zquery (Z_Query *q)
     yaz_log_zquery_level(YLOG_LOG, q);
 }
 
-void wrbuf_diags(WRBUF b, int num_diagnostics,Z_DiagRec **diags)
-{
-    /* we only dump the first diag - that keeps the log cleaner. */
-    wrbuf_printf(b," ERROR ");
-    if (diags[0]->which != Z_DiagRec_defaultFormat)
-        wrbuf_printf(b,"(diag not in default format?)");
-    else
-    {
-        Z_DefaultDiagFormat *e=diags[0]->u.defaultFormat;
-        if (e->condition)
-            wrbuf_printf(b, "%d ",*e->condition);
-        else
-            wrbuf_printf(b, "?? ");
-        if ((e->which==Z_DefaultDiagFormat_v2Addinfo) && (e->u.v2Addinfo))
-            wrbuf_printf(b,"%s ",e->u.v2Addinfo);
-        else if ((e->which==Z_DefaultDiagFormat_v3Addinfo) && (e->u.v3Addinfo))
-            wrbuf_printf(b,"%s ",e->u.v3Addinfo);
-    }
-}
 /*
  * Local variables:
  * c-basic-offset: 4