No unsigned char's in public API (except for iconv)
[yaz-moved-to-github.git] / src / ber_bit.c
index 774d370..b2242c4 100644 (file)
@@ -1,5 +1,5 @@
 /* This file is part of the YAZ toolkit.
- * Copyright (C) 1995-2012 Index Data
+ * Copyright (C) 1995-2013 Index Data
  * See the file LICENSE for details.
  */
 
@@ -20,7 +20,7 @@
 int ber_bitstring(ODR o, Odr_bitmask *p, int cons)
 {
     int res, len;
-    const unsigned char *base;
+    const char *base;
 
     switch (o->direction)
     {
@@ -70,7 +70,7 @@ int ber_bitstring(ODR o, Odr_bitmask *p, int cons)
             return 0;
         if (p->top < 0)
             return 1;
-        if (odr_write(o, p->bits, p->top + 1) < 0)
+        if (odr_write2(o, p->bits, p->top + 1) < 0)
             return 0;
         return 1;
     case ODR_PRINT: