From f195eff4764999fcd7c14e474c6ecb7862b3800f Mon Sep 17 00:00:00 2001 From: Marc Cromme Date: Mon, 16 Apr 2007 13:57:25 +0000 Subject: [PATCH] added asserts on service struct passed to reclist_insert --- src/reclists.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/reclists.c b/src/reclists.c index d27b69f..e0bf96d 100644 --- a/src/reclists.c +++ b/src/reclists.c @@ -1,4 +1,4 @@ -/* $Id: reclists.c,v 1.9 2007-04-16 13:22:17 marc Exp $ +/* $Id: reclists.c,v 1.10 2007-04-16 13:57:25 marc Exp $ Copyright (c) 2006-2007, Index Data. This file is part of Pazpar2. @@ -212,7 +212,10 @@ struct record_cluster *reclist_insert( struct conf_service *service, unsigned int bucket; struct reclist_bucket **p; struct record_cluster *cluster = 0; - /*struct conf_service *service = global_parameters.server->service;*/ + + assert(service); + assert(service->num_metadata); + assert(service->num_sortkeys); bucket = hash((unsigned char*) merge_key) & l->hashmask; for (p = &l->hashtable[bucket]; *p; p = &(*p)->next) -- 1.7.10.4