From: Adam Dickmeiss Date: Fri, 17 May 2013 12:44:38 +0000 (+0200) Subject: marcmap: fix for fopen fail X-Git-Tag: v1.6.31~17 X-Git-Url: http://lists.indexdata.dk/?a=commitdiff_plain;h=6110a4dcdf8f269968c6a30792f47dacba3929b6;p=pazpar2-moved-to-github.git marcmap: fix for fopen fail --- diff --git a/src/marcmap.c b/src/marcmap.c index 42491e2..59cf858 100644 --- a/src/marcmap.c +++ b/src/marcmap.c @@ -54,6 +54,8 @@ struct marcmap *marcmap_load(const char *filename, NMEM nmem) mm = NULL; mmhead = NULL; fp = fopen(filename, "r"); + if (!fp) + return mmhead; while ((c = getc(fp) ) != EOF) {