/* This file is part of the YAZ toolkit.
- * Copyright (C) 1995-2009 Index Data
+ * Copyright (C) 1995-2010 Index Data
* See the file LICENSE for details.
*/
Odr_oct *oct = apt->term->u.general;
if (oct->len > 0 && oct->buf[0] >= '0' && oct->buf[0] <= '9')
{
- char *endptr;
WRBUF hits_str = wrbuf_alloc();
wrbuf_write(hits_str, (const char *) oct->buf, oct->len);
h = odr_atoi(wrbuf_cstr(hits_str));
return 0;
}
len = q->term->term->u.general->len;
- if (len >= sizeof(term))
+ if (len >= (int ) sizeof(term))
len = sizeof(term)-1;
memcpy(term, q->term->term->u.general->buf, len);
term[len] = '\0';