From 2b46eb1c8c473cdc96cc56c26a3e8093376dc59f Mon Sep 17 00:00:00 2001 From: Sebastian Hammer Date: Fri, 11 May 2007 16:57:42 +0000 Subject: [PATCH] Ignore targets with no name associated -- this is one way to eliminate 'ghost' targets without settins -- at least a name must be set before a search can proceed. --- src/database.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/database.c b/src/database.c index 342cbc9..2553b7c 100644 --- a/src/database.c +++ b/src/database.c @@ -1,4 +1,4 @@ -/* $Id: database.c,v 1.25 2007-04-23 21:05:23 adam Exp $ +/* $Id: database.c,v 1.26 2007-05-11 16:57:42 quinn Exp $ Copyright (c) 2006-2007, Index Data. This file is part of Pazpar2. @@ -236,6 +236,8 @@ int session_grep_databases(struct session *se, struct database_criterion *cl, { if (p->settings && p->settings[PZ_ALLOW] && *p->settings[PZ_ALLOW]->value == '0') continue; + if (!p->settings[PZ_NAME]) + continue; if (database_match_criteria(p->settings, cl)) { (*fun)(se, p); -- 1.7.10.4