X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=bfile%2Fmfile.c;h=ce4279afc966159ca3bed910e565041b6a055a3f;hb=66291dd47d5d44e4af1e3f9b1158bd5c6a32f0c3;hp=189f2020f1e732e417b78610f63d5231a2383bfa;hpb=6c9fcd3b5d3108702fa1ffc92dab4ab6060f9a19;p=idzebra-moved-to-github.git diff --git a/bfile/mfile.c b/bfile/mfile.c index 189f202..ce4279a 100644 --- a/bfile/mfile.c +++ b/bfile/mfile.c @@ -1,4 +1,4 @@ -/* $Id: mfile.c,v 1.58 2005-01-15 19:38:17 adam Exp $ +/* $Id: mfile.c,v 1.62 2005-06-14 20:28:53 adam Exp $ Copyright (C) 1995-2005 Index Data ApS @@ -32,7 +32,8 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA #include #ifdef WIN32 #include -#else +#endif +#if HAVE_UNISTD_H #include #endif #include @@ -43,7 +44,8 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA #include #include -#include +#include +#include #include "mfile.h" static int scan_areadef(MFile_area ma, const char *ad, const char *base) @@ -160,7 +162,7 @@ static zint file_position(MFile mf, zint pos, int offset) if (!mf->wr && errno == ENOENT && off == 0) return -2; yaz_log (YLOG_WARN|YLOG_ERRNO, "Failed to open %s", mf->files[c].path); - return -1; + return -1; } } ps = pos - off;