X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;f=src%2Flogic.c;h=2a0e9617a11cb9d1ffd08255ea2ff9b3748fe760;hb=315af5c601a268e2d0da60477c3470a6c12654c9;hp=bce0ad11d610ab81edd03e21196d9b125dab170b;hpb=f030fa5726d942a82ffebb2ee22e35338ccfed78;p=pazpar2-moved-to-github.git diff --git a/src/logic.c b/src/logic.c index bce0ad1..2a0e961 100644 --- a/src/logic.c +++ b/src/logic.c @@ -1,4 +1,4 @@ -/* $Id: logic.c,v 1.18 2007-04-22 16:41:42 adam Exp $ +/* $Id: logic.c,v 1.19 2007-04-23 08:15:22 marc Exp $ Copyright (c) 2006-2007, Index Data. This file is part of Pazpar2. @@ -509,8 +509,9 @@ static void add_facet(struct session *s, const char *type, const char *value) if (i == SESSION_MAX_TERMLISTS) { yaz_log(YLOG_FATAL, "Too many termlists"); - exit(1); + return; } + s->termlists[i].name = nmem_strdup(s->nmem, type); s->termlists[i].termlist = termlist_create(s->nmem, s->expected_maxrecs, 15); s->num_termlists = i + 1; @@ -562,7 +563,7 @@ static xmlDoc *normalize_record(struct client *cl, Z_External *rec) yaz_log(YLOG_FATAL, "Unknown native_syntax in normalize_record from %s", db->url); - exit(1); + return 0; } if (global_parameters.dump_records){ @@ -1144,7 +1145,7 @@ static int connection_connect(struct connection *con) if (!(link = cs_create(tcpip_type, 0, PROTO_Z3950))) { yaz_log(YLOG_FATAL|YLOG_ERRNO, "Failed to create comstack"); - exit(1); + return -1; } if (0 == strlen(global_parameters.zproxy_override)){