Added type signed/unsigned char type casts to make GCC 4 happy.
authorAdam Dickmeiss <adam@indexdata.dk>
Mon, 22 Aug 2005 09:04:17 +0000 (09:04 +0000)
committerAdam Dickmeiss <adam@indexdata.dk>
Mon, 22 Aug 2005 09:04:17 +0000 (09:04 +0000)
index/extract.c
index/zebraapi.c
index/zrpn.c
index/zserver.c

index e7b79aa..33fc1e3 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: extract.c,v 1.191 2005-08-19 11:03:53 adam Exp $
+/* $Id: extract.c,v 1.192 2005-08-22 09:04:17 adam Exp $
    Copyright (C) 1995-2005
    Index Data ApS
 
@@ -1684,9 +1684,9 @@ static void extract_add_sort_string (RecWord *p, const char *str, int length)
     {
         int set, use, slen;
 
-        off += key_SU_decode(&set, sk->buf + off);
-        off += key_SU_decode(&use, sk->buf + off);
-        off += key_SU_decode(&slen, sk->buf + off);
+        off += key_SU_decode(&set, (unsigned char *) sk->buf + off);
+        off += key_SU_decode(&use, (unsigned char *) sk->buf + off);
+        off += key_SU_decode(&slen, (unsigned char *) sk->buf + off);
         off += slen;
         if (p->attrSet == set && p->attrUse == use)
             return;
@@ -1930,9 +1930,9 @@ void extract_flushSortKeys (ZebraHandle zh, SYSNO sysno,
     {
         int set, use, slen;
         
-        off += key_SU_decode(&set, sk->buf + off);
-        off += key_SU_decode(&use, sk->buf + off);
-        off += key_SU_decode(&slen, sk->buf + off);
+        off += key_SU_decode(&set, (unsigned char *) sk->buf + off);
+        off += key_SU_decode(&use, (unsigned char *) sk->buf + off);
+        off += key_SU_decode(&slen, (unsigned char *) sk->buf + off);
         
         sortIdx_type(sortIdx, use);
         if (cmd == 1)
index ce56154..40aa1cc 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: zebraapi.c,v 1.183 2005-08-19 09:21:34 adam Exp $
+/* $Id: zebraapi.c,v 1.184 2005-08-22 09:04:18 adam Exp $
    Copyright (C) 1995-2005
    Index Data ApS
 
@@ -1239,13 +1239,13 @@ ZEBRA_RES zebra_admin_import_segment (ZebraHandle zh, Z_Segment *segment)
                Odr_oct *oct = fragment->u.notExternallyTagged;
                sysno = 0;
                
-               if ( zebra_update_record(zh, 
-                                        0, /* record Type */
-                                        &sysno,
-                                        0, /* match */
-                                        0, /* fname */
-                                        oct->buf, oct->len,
-                                        0) == ZEBRA_FAIL)
+               if (zebra_update_record(zh, 
+                                       0, /* record Type */
+                                       &sysno,
+                                       0, /* match */
+                                       0, /* fname */
+                                       (const char *) oct->buf, oct->len,
+                                       0) == ZEBRA_FAIL)
                    res = ZEBRA_FAIL;
            }
        }
index d3a12bd..135f68b 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: zrpn.c,v 1.203 2005-08-08 12:04:02 adam Exp $
+/* $Id: zrpn.c,v 1.204 2005-08-22 09:04:18 adam Exp $
    Copyright (C) 1995-2005
    Index Data ApS
 
@@ -236,7 +236,7 @@ static void add_isam_p(const char *name, const char *info,
         int set, use;
         char term_tmp[IT_MAX_WORD];
         int su_code = 0;
-        int len = key_SU_decode (&su_code, name);
+        int len = key_SU_decode (&su_code, (const unsigned char *) name);
         
         zebra_term_untrans  (p->zh, p->reg_type, term_tmp, name+len+1);
         yaz_log(log_level_rpn, "grep: %d %c %s", su_code, name[len], term_tmp);
@@ -1390,7 +1390,7 @@ static ZEBRA_RES zapt_term_to_utf8(ZebraHandle zh, Z_AttributesPlusTerm *zapt,
     case Z_Term_general:
         if (zh->iconv_to_utf8 != 0)
         {
-            char *inbuf = term->u.general->buf;
+            char *inbuf = (char *) term->u.general->buf;
             size_t inleft = term->u.general->len;
             char *outbuf = termz;
             size_t outleft = IT_MAX_WORD-1;
index c0eacbe..118887a 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: zserver.c,v 1.138 2005-08-09 09:35:25 adam Exp $
+/* $Id: zserver.c,v 1.139 2005-08-22 09:04:18 adam Exp $
    Copyright (C) 1995-2005
    Index Data ApS
 
@@ -650,9 +650,10 @@ int bend_esrequest (void *handle, bend_esrequest_rr *rr)
                        {
                             int r = zebra_admin_exchange_record (
                                 zh,
-                                rec->u.octet_aligned->buf,
+                                (const char *) rec->u.octet_aligned->buf,
                                 rec->u.octet_aligned->len,
-                                opaque_recid->buf, opaque_recid->len,
+                                (const char *) opaque_recid->buf,
+                               opaque_recid->len,
                                 action);
                             if (r)
                             {
@@ -673,7 +674,7 @@ int bend_esrequest (void *handle, bend_esrequest_rr *rr)
                                    &sysno,
                                    0, /* match */
                                    0, /* fname */
-                                   rec->u.octet_aligned->buf,
+                                   (const char *) rec->u.octet_aligned->buf,
                                    rec->u.octet_aligned->len,
                                    0);
                                if (r == ZEBRA_FAIL)
@@ -691,7 +692,7 @@ int bend_esrequest (void *handle, bend_esrequest_rr *rr)
                                    &sysno,
                                    0, /* match */
                                    0, /* fname */
-                                   rec->u.octet_aligned->buf,
+                                   (const char *) rec->u.octet_aligned->buf,
                                    rec->u.octet_aligned->len,
                                    1);
                                if (r == ZEBRA_FAIL)
@@ -708,7 +709,7 @@ int bend_esrequest (void *handle, bend_esrequest_rr *rr)
                                    &sysno,
                                    0, /* match */
                                    0, /* fname */
-                                   rec->u.octet_aligned->buf,
+                                   (const char *) rec->u.octet_aligned->buf,
                                    rec->u.octet_aligned->len,
                                    0);
                                if (r == ZEBRA_FAIL)