-/* $Id: kinput.c,v 1.71 2006-03-30 09:52:15 adam Exp $
- Copyright (C) 1995-2005
+/* $Id: kinput.c,v 1.77 2006-10-29 17:20:01 adam Exp $
+ Copyright (C) 1995-2006
Index Data ApS
This file is part of the Zebra server.
for more details.
You should have received a copy of the GNU General Public License
-along with Zebra; see the file LICENSE.zebra. If not, write to the
-Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA.
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
*/
#include <fcntl.h>
Res res;
};
-#if 1
+#if 0
static void pkey(const char *b, int mode)
{
key_logdump_txt(YLOG_LOG, b, mode ? "i" : "d");
int no_iterations;
};
-static struct heap_info *key_heap_malloc()
+static struct heap_info *key_heap_malloc(void)
{ /* malloc and clear it */
struct heap_info *hi;
hi = (struct heap_info *) xmalloc (sizeof(*hi));
void key_heap_destroy (struct heap_info *hi, int nkeys)
{
int i;
- yaz_log (YLOG_DEBUG, "key_heap_destroy");
- yaz_log (YLOG_DEBUG, "key_heap_destroy nk=%d",nkeys);
if (!hi->raw_reading)
for (i = 0; i<=nkeys; i++)
xfree (hi->info.buf[i]);
return 0;
--(zh->reg->ptr_i);
cp=(zh->reg->key_buf)[zh->reg->ptr_top - ptr_i];
- yaz_log (YLOG_DEBUG, " raw: i=%ld top=%ld cp=%p", (long) ptr_i,
- (long) zh->reg->ptr_top, cp);
strcpy(name, cp);
memcpy(key, cp+strlen(name)+1, KEY_SIZE);
hi->no_iterations++;
#define PR_KEY_LOW 0
#define PR_KEY_TOP 0
-#if 1
+#if 0
/* for debugging only */
static void print_dict_item(ZebraHandle zh, const char *s)
{
char *dict_info;
strcpy (this_name, hci->cur_name);
- assert (hci->cur_name[1]);
+ assert (hci->cur_name[0]);
hi->no_diffs++;
if ((dict_info = dict_lookup (hi->reg->dict, hci->cur_name)))
{
int mode;
strcpy (this_name, hci->cur_name);
- assert (hci->cur_name[1]);
+ assert (hci->cur_name[0]);
hi->no_diffs++;
while (heap_cread_item2(hci, &dst, &mode))
char *dict_info;
strcpy (this_name, hci->cur_name);
- assert (hci->cur_name[1]);
+ assert (hci->cur_name[0]);
hi->no_diffs++;
#if 0
char *dict_info;
strcpy (this_name, hci->cur_name);
- assert (hci->cur_name[1]);
+ assert (hci->cur_name[0]);
hi->no_diffs++;
if (!(dict_info = dict_lookup (hi->reg->dict, hci->cur_name)))
{
key_heap_destroy (hi, nkeys);
}
+/*
+ * Local variables:
+ * c-basic-offset: 4
+ * indent-tabs-mode: nil
+ * End:
+ * vim: shiftwidth=4 tabstop=8 expandtab
+ */
+