2 * Copyright (C) 1995-2005, Index Data ApS
3 * See the file LICENSE for details.
5 * $Id: waislen.c,v 1.3 2005-01-15 19:47:14 adam Exp $
9 * \brief Implements WAIS package handling
13 #include <yaz/comstack.h>
14 #include <yaz/tcpip.h>
16 * Return length of WAIS package or 0
18 int completeWAIS(const unsigned char *buf, int len)
26 /* calculate length */
27 for (i = 0; i < 10; i++)
28 lval = lval * 10 + (buf[i] - '0');